[gnome-shell] search: propagate GAppInfo to SearchProvider
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] search: propagate GAppInfo to SearchProvider
- Date: Mon, 19 Nov 2012 17:02:36 +0000 (UTC)
commit 6e46ddaad34a68c1382827823dd258fbabb7c209
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Thu Nov 1 10:33:22 2012 -0400
search: propagate GAppInfo to SearchProvider
Save the GAppInfo in the provider object; this will be used when
filtering.
https://bugzilla.gnome.org/show_bug.cgi?id=687491
js/ui/remoteSearch.js | 7 +++----
js/ui/search.js | 3 ++-
2 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/js/ui/remoteSearch.js b/js/ui/remoteSearch.js
index 58283d5..21e3d0f 100644
--- a/js/ui/remoteSearch.js
+++ b/js/ui/remoteSearch.js
@@ -91,8 +91,7 @@ function loadRemoteSearchProvidersFromDir(dir, loadedProviders, addProviderCallb
continue;
}
- remoteProvider = new RemoteSearchProvider(appInfo.get_name(),
- appInfo.get_icon(),
+ remoteProvider = new RemoteSearchProvider(appInfo,
busName,
objectPath);
loadedProviders[objectPath] = remoteProvider;
@@ -111,11 +110,11 @@ const RemoteSearchProvider = new Lang.Class({
Name: 'RemoteSearchProvider',
Extends: Search.SearchProvider,
- _init: function(title, icon, dbusName, dbusPath) {
+ _init: function(appInfo, dbusName, dbusPath) {
this._proxy = new SearchProviderProxy(Gio.DBus.session,
dbusName, dbusPath, Lang.bind(this, this._onProxyConstructed));
- this.parent(title.toUpperCase());
+ this.parent(appInfo.get_name().toUpperCase(), appInfo);
this._cancellable = new Gio.Cancellable();
},
diff --git a/js/ui/search.js b/js/ui/search.js
index 22f53d9..f106e91 100644
--- a/js/ui/search.js
+++ b/js/ui/search.js
@@ -74,8 +74,9 @@ const SearchResultDisplay = new Lang.Class({
const SearchProvider = new Lang.Class({
Name: 'SearchProvider',
- _init: function(title) {
+ _init: function(title, appInfo) {
this.title = title;
+ this.appInfo = appInfo;
this.searchSystem = null;
},
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]