From 6a36a68f3289c3160c328382e1ae9af831a7b0bb Mon Sep 17 00:00:00 2001 From: Rui Matos Date: Thu, 29 May 2014 15:27:42 +0200 Subject: [PATCH] ibusManager: Spawn ibus-daemon gnome-settings-daemon doesn't this for us anymore. Note that ibus-daemon isn't DBus activatable but just spawning it is fine because it does its own single instance management. The library notifies us when it shows up and goes away through the connected and disconnected signals. https://bugzilla.gnome.org/show_bug.cgi?id=736435 --- js/misc/ibusManager.js | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/js/misc/ibusManager.js b/js/misc/ibusManager.js index c571fb7ca..40a33a642 100644 --- a/js/misc/ibusManager.js +++ b/js/misc/ibusManager.js @@ -1,5 +1,6 @@ // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*- +const Gio = imports.gi.Gio; const Lang = imports.lang; const Signals = imports.signals; @@ -44,6 +45,17 @@ const IBusManager = new Lang.Class({ // Need to set this to get 'global-engine-changed' emitions this._ibus.set_watch_ibus_signal(true); this._ibus.connect('global-engine-changed', Lang.bind(this, this._engineChanged)); + + this._spawn(); + }, + + _spawn: function() { + try { + Gio.Subprocess.new(['ibus-daemon', '--xim', '--panel', 'disable'], + Gio.SubprocessFlags.NONE); + } catch(e) { + log('Failed to launch ibus-daemon: ' + e.message); + } }, _clear: function() { @@ -58,6 +70,8 @@ const IBusManager = new Lang.Class({ this._currentEngineName = null; this.emit('ready', false); + + this._spawn(); }, _onConnected: function() {