GNOME Bugzilla – Bug 579872
Context menu activated by keyboard popping up at the wrong location
Last modified: 2017-08-28 11:14:37 UTC
When the context menu is activated by clicking with the right mouse button, the context menu appears at the location of the mouse pointer. This is ok. When the context menu is activated by the context menu key (situated between the right control key and the Windows key on most keyboards), the context menu still appears at the location of the mouse pointer. This is not ok. It should appear at the location of the object having focus, and being the subject of the context menu. The location of the mouse pointer should be ignored in this case. Other information: There is a bugreport on this subject in Ubuntu's launcpad: https://bugs.launchpad.net/ubuntu/+source/gtk+2.0/+bug/160738
Which context menu in which application are you talking about? This is an application bug; it needs to use a menu positioning function to place the menu at the object.
From the upstream report, this is nautilus. It might be reproducible in other applications as well, but it's always the application responsibility to position the menu properly. Moving to nautilus.
s/upstream/downstream
FWIW, I can reproduce this bug in Nautilus 2.28.0 (in Ubuntu Karmic), but the bug doesn't manifest in Firefox 3.5.3. This supports comment 2 -- that it's the application's responsibility to correctly position the menu. Firefox apparently does this correctly, whereas Nautilus does not. (Nautilus *does* do this right in one instance -- when the location bar is focused, via Ctrl+L. In that case, the context menu appears over the location bar, regardless of mouse position.)
*** This bug has been marked as a duplicate of bug 102666 ***