From 7a049499f6e6a7c04be76c74948df4c0e48d9123 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alberts=20Muktup=C4=81vels?= Date: Sat, 13 Dec 2014 23:15:18 +0200 Subject: [PATCH] ui/shellDBus.js: move key grabber to org.gnome.Shell.KeyGrabber --- js/ui/shellDBus.js | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/js/ui/shellDBus.js b/js/ui/shellDBus.js index 14dba7292..ee09d16d2 100644 --- a/js/ui/shellDBus.js +++ b/js/ui/shellDBus.js @@ -33,6 +33,14 @@ const GnomeShellIface = ' \ \ \ \ + \ + \ + \ + \ +'; + +const GnomeShellKeyGrabberIface = ' \ + \ \ \ \ @@ -50,9 +58,6 @@ const GnomeShellIface = ' \ \ \ \ - \ - \ - \ \ '; @@ -83,6 +88,9 @@ const GnomeShell = new Lang.Class({ this._dbusImpl = Gio.DBusExportedObject.wrapJSObject(GnomeShellIface, this); this._dbusImpl.export(Gio.DBus.session, '/org/gnome/Shell'); + this._dbusKeyGrabberImpl = Gio.DBusExportedObject.wrapJSObject(GnomeShellKeyGrabberIface, this); + this._dbusKeyGrabberImpl.export(Gio.DBus.session, '/org/gnome/Shell/KeyGrabber'); + this._extensionsService = new GnomeShellExtensions(); this._screenshotService = new Screenshot.ScreenshotService(); @@ -197,13 +205,13 @@ const GnomeShell = new Lang.Class({ if (!destination) return; - let connection = this._dbusImpl.get_connection(); - let info = this._dbusImpl.get_info(); + let connection = this._dbusKeyGrabberImpl.get_connection(); + let info = this._dbusKeyGrabberImpl.get_info(); let params = { 'device-id': GLib.Variant.new('u', deviceid), 'timestamp': GLib.Variant.new('u', timestamp), 'action-mode': GLib.Variant.new('u', Main.actionMode) }; connection.emit_signal(destination, - this._dbusImpl.get_object_path(), + this._dbusKeyGrabberImpl.get_object_path(), info ? info.name : null, 'AcceleratorActivated', GLib.Variant.new('(ua{sv})', [action, params]));