[gnome-shell/wip/re-search-v2: 2/28] app-display: use a GAppInfo for the settings provider
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/re-search-v2: 2/28] app-display: use a GAppInfo for the settings provider
- Date: Mon, 3 Dec 2012 18:10:15 +0000 (UTC)
commit 2f8d08671e90227cf3c46d4fd0d8f540a73ba43f
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Mon Nov 26 17:01:44 2012 -0500
app-display: use a GAppInfo for the settings provider
this._gnomecc is currently unused; we actually need a GAppInfo for this
provider if we want to display an icon next to it (see future commits),
so just turn it into one.
We might move this to an external provider altogether in the future.
js/ui/appDisplay.js | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/js/ui/appDisplay.js b/js/ui/appDisplay.js
index a80b684..9e56922 100644
--- a/js/ui/appDisplay.js
+++ b/js/ui/appDisplay.js
@@ -1,6 +1,7 @@
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
const Clutter = imports.gi.Clutter;
+const Gio = imports.gi.Gio;
const GLib = imports.gi.GLib;
const Gtk = imports.gi.Gtk;
const GMenu = imports.gi.GMenu;
@@ -377,7 +378,7 @@ const SettingsSearchProvider = new Lang.Class({
this.parent(_("SETTINGS"));
this._appSys = Shell.AppSystem.get_default();
- this._gnomecc = this._appSys.lookup_app('gnome-control-center.desktop');
+ this.appInfo = Gio.DesktopAppInfo.new('gnome-control-center.desktop');
},
getResultMetas: function(prefs, callback) {
@@ -417,6 +418,11 @@ const SettingsSearchProvider = new Lang.Class({
let app = resultMeta['id'];
let icon = new AppWellIcon(app);
return icon.actor;
+ },
+
+ launchSearch: function(terms) {
+ // FIXME: this should be a remote search provider
+ this.appInfo.launch([], global.create_app_launch_context());
}
});
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]