messageTray: fix a warning

Check for click in keyboardBox rather than Main.keyboard.actor, since
the latter won't exist when the keyboard is hidden.

https://bugzilla.gnome.org/show_bug.cgi?id=658598
This commit is contained in:
Dan Winship 2011-09-08 16:50:32 -04:00
parent 1d14488a4f
commit fd25cf30ff

View File

@ -284,7 +284,8 @@ FocusGrabber.prototype = {
let source = event.get_source(); let source = event.get_source();
switch (event.type()) { switch (event.type()) {
case Clutter.EventType.BUTTON_PRESS: case Clutter.EventType.BUTTON_PRESS:
if (!this.actor.contains(source) && !Main.keyboard.actor.contains(source)) if (!this.actor.contains(source) &&
!Main.layoutManager.keyboardBox.contains(source))
this.emit('button-pressed', source); this.emit('button-pressed', source);
break; break;
case Clutter.EventType.KEY_PRESS: case Clutter.EventType.KEY_PRESS: