panel: Check for appMenu button's reactivity before opening

When the appMenu is not available, for instance when no windows are
open (on the current workspace), we make its actor unreactive to
"hide" it from keynav. However the menu can still be triggered
erroneously when using the corresponding keyboard shortcut, so
add a check for the actor's reactivity there as well.

https://bugzilla.gnome.org/show_bug.cgi?id=676316
This commit is contained in:
Florian Müllner 2012-05-18 16:04:47 +02:00
parent a3bbb7be14
commit 82c2f5221d

View File

@ -1115,8 +1115,8 @@ const Panel = new Lang.Class({
openAppMenu: function() {
let menu = this._appMenu.menu;
if (Main.overview.visible || menu.isOpen)
return;
if (!this._appMenu.actor.reactive || menu.isOpen)
return;
menu.open();
menu.actor.navigate_focus(null, Gtk.DirectionType.TAB_FORWARD, false);