remoteSearch: fix fallout from RemoteSearchProvider refactor
RemoteSearchProvider.title was removed, but we were still using it in a few places. https://bugzilla.gnome.org/show_bug.cgi?id=692723
This commit is contained in:
parent
2d79c7333f
commit
a9ad9d5e6d
@ -137,8 +137,12 @@ function remoteProvidersLoaded(loadState) {
|
|||||||
idxB = sortOrder.indexOf(appIdB);
|
idxB = sortOrder.indexOf(appIdB);
|
||||||
|
|
||||||
// if no provider is found in the order, use alphabetical order
|
// if no provider is found in the order, use alphabetical order
|
||||||
if ((idxA == -1) && (idxB == -1))
|
if ((idxA == -1) && (idxB == -1)) {
|
||||||
return GLib.utf8_collate(providerA.title, providerB.title);
|
let nameA = providerA.appInfo.get_name();
|
||||||
|
let nameB = providerB.appInfo.get_name();
|
||||||
|
|
||||||
|
return GLib.utf8_collate(nameA, nameB);
|
||||||
|
}
|
||||||
|
|
||||||
if (numSorted > 1) {
|
if (numSorted > 1) {
|
||||||
// if providerA is the last, it goes after everything
|
// if providerA is the last, it goes after everything
|
||||||
@ -217,7 +221,7 @@ const RemoteSearchProvider = new Lang.Class({
|
|||||||
Lang.bind(this, this._getResultsFinished),
|
Lang.bind(this, this._getResultsFinished),
|
||||||
this._cancellable);
|
this._cancellable);
|
||||||
} catch(e) {
|
} catch(e) {
|
||||||
log('Error calling GetInitialResultSet for provider %s: %s'.format( this.title, e.toString()));
|
log('Error calling GetInitialResultSet for provider %s: %s'.format(this.id, e.toString()));
|
||||||
this.searchSystem.pushResults(this, []);
|
this.searchSystem.pushResults(this, []);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -230,7 +234,7 @@ const RemoteSearchProvider = new Lang.Class({
|
|||||||
Lang.bind(this, this._getResultsFinished),
|
Lang.bind(this, this._getResultsFinished),
|
||||||
this._cancellable);
|
this._cancellable);
|
||||||
} catch(e) {
|
} catch(e) {
|
||||||
log('Error calling GetSubsearchResultSet for provider %s: %s'.format(this.title, e.toString()));
|
log('Error calling GetSubsearchResultSet for provider %s: %s'.format(this.id, e.toString()));
|
||||||
this.searchSystem.pushResults(this, []);
|
this.searchSystem.pushResults(this, []);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -261,7 +265,7 @@ const RemoteSearchProvider = new Lang.Class({
|
|||||||
Lang.bind(this, this._getResultMetasFinished, callback),
|
Lang.bind(this, this._getResultMetasFinished, callback),
|
||||||
this._cancellable);
|
this._cancellable);
|
||||||
} catch(e) {
|
} catch(e) {
|
||||||
log('Error calling GetResultMetas for provider %s: %s'.format(this.title, e.toString()));
|
log('Error calling GetResultMetas for provider %s: %s'.format(this.id, e.toString()));
|
||||||
callback([]);
|
callback([]);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user