searchDisplay: Remove clearDisplayForProvider
Since the two paths that call this want to keep the actor in two different states, it makes sense to just call the one function that's the same between both individually. https://bugzilla.gnome.org/show_bug.cgi?id=693836
This commit is contained in:
parent
e602199bfb
commit
5ab4c484a5
@ -417,12 +417,6 @@ const SearchResults = new Lang.Class({
|
||||
}
|
||||
},
|
||||
|
||||
_clearDisplayForProvider: function(provider) {
|
||||
let meta = this._metaForProvider(provider);
|
||||
meta.resultDisplay.clear();
|
||||
meta.actor.hide();
|
||||
},
|
||||
|
||||
reset: function() {
|
||||
this._searchSystem.reset();
|
||||
this._statusBin.hide();
|
||||
@ -489,7 +483,8 @@ const SearchResults = new Lang.Class({
|
||||
let meta = this._metaForProvider(provider);
|
||||
|
||||
if (providerResults.length == 0) {
|
||||
this._clearDisplayForProvider(provider);
|
||||
meta.resultDisplay.clear();
|
||||
meta.actor.hide();
|
||||
meta.resultDisplay.setResults([], []);
|
||||
this._maybeSetInitialSelection();
|
||||
this._updateStatusText();
|
||||
@ -503,7 +498,7 @@ const SearchResults = new Lang.Class({
|
||||
provider.canLaunchSearch;
|
||||
|
||||
provider.getResultMetas(results, Lang.bind(this, function(metas) {
|
||||
this._clearDisplayForProvider(provider);
|
||||
meta.resultDisplay.clear();
|
||||
meta.actor.show();
|
||||
|
||||
// Hiding drops the key focus if we have it
|
||||
|
Loading…
Reference in New Issue
Block a user