From aaa846da1793cbd7fba530cc0ca056f553e35ceb Mon Sep 17 00:00:00 2001 From: Colin Walters Date: Wed, 11 Feb 2009 11:31:33 -0500 Subject: [PATCH] Bug 571313 - Refocus search field every time overlay is shown Before the run dialog was changing the focus, but because we were only setting it once, we ended up with nothing focused after the run dialog was destroyed. --- js/ui/overlay.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/js/ui/overlay.js b/js/ui/overlay.js index 81de87b39..1a7582d66 100644 --- a/js/ui/overlay.js +++ b/js/ui/overlay.js @@ -112,7 +112,6 @@ Sideshow.prototype = { height: searchIconTexture.height, text: ""}); this.actor.add_actor(this._searchEntry); - global.stage.set_key_focus(this._searchEntry); this._searchQueued = false; this._searchActive = false; this._searchEntry.connect('notify::text', function (se, prop) { @@ -261,6 +260,8 @@ Sideshow.prototype = { }, show: function() { + let global = Shell.Global.get(); + this._appDisplay.show(); this._docDisplay.show(); this._appDisplay.selectFirstItem(); @@ -268,6 +269,7 @@ Sideshow.prototype = { this._docDisplay.selectFirstItem(); else this._docDisplay.unsetSelected(); + global.stage.set_key_focus(this._searchEntry); }, hide: function() {