Fix search handling when typing multiple searches in the search box
In the current implementation of the search entry, when replacing a selected search term with another term, the first character of the replacement is prepended to the hint text rather than starting a new search. This fix makes sure that the focus is not lost when changing the selected search term. https://bugzilla.gnome.org/show_bug.cgi?id=636341
This commit is contained in:
parent
f0622c1896
commit
35c85d9fac
@ -162,6 +162,13 @@ SearchTab.prototype = {
|
||||
hide: function() {
|
||||
BaseTab.prototype.hide.call(this);
|
||||
|
||||
// Leave the entry focused when it doesn't have any text;
|
||||
// when replacing a selected search term, Clutter emits
|
||||
// two 'text-changed' signals, one for deleting the previous
|
||||
// text and one for the new one - the second one is handled
|
||||
// incorrectly when we remove focus
|
||||
// (https://bugzilla.gnome.org/show_bug.cgi?id=636341) */
|
||||
if (this._text.text != '')
|
||||
this._reset();
|
||||
},
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user