Merge lp:~mterry/unity-greeter/spawn-gsd into lp:unity-greeter

Proposed by Michael Terry
Status: Merged
Approved by: Robert Ancell
Approved revision: 746
Merged at revision: 746
Proposed branch: lp:~mterry/unity-greeter/spawn-gsd
Merge into: lp:unity-greeter
Diff against target: 62 lines (+11/-13)
3 files modified
configure.ac (+6/-0)
src/config.vapi (+2/-1)
src/settings-daemon.vala (+3/-12)
To merge this branch: bzr merge lp:~mterry/unity-greeter/spawn-gsd
Reviewer Review Type Date Requested Status
Robert Ancell Approve
Review via email: mp+145721@code.launchpad.net

Description of the change

Spawn gsd directly.

And fix some glue code so that we can stuff variables like GSD_BINARY directly in config.h without having to define them on via CFLAGS.

To post a comment you must log in.
Revision history for this message
Robert Ancell (robert-ancell) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'configure.ac'
2--- configure.ac 2013-01-22 21:17:22 +0000
3+++ configure.ac 2013-01-30 20:36:25 +0000
4@@ -30,6 +30,12 @@
5 INDICATORDIR=`$PKG_CONFIG --variable=indicatordir indicator3-0.4`
6 AC_SUBST(INDICATORDIR)
7
8+GSD_BINARY=`$PKG_CONFIG --variable=binary gnome-settings-daemon`
9+if test -z "$GSD_BINARY"; then
10+ AC_MSG_ERROR([Could not find path to gnome-settings-daemon binary])
11+fi
12+AC_DEFINE_UNQUOTED([GSD_BINARY], ["$GSD_BINARY"], [Path to g-s-d])
13+
14 dnl ###########################################################################
15 dnl Internationalization
16 dnl ###########################################################################
17
18=== modified file 'src/config.vapi'
19--- src/config.vapi 2012-08-03 13:31:27 +0000
20+++ src/config.vapi 2013-01-30 20:36:25 +0000
21@@ -1,4 +1,4 @@
22-[CCode (cprefix = "", lower_case_cprefix = "")]
23+[CCode (cprefix = "", lower_case_cprefix = "", cheader_filename = "config.h")]
24 namespace Config
25 {
26 public const string GETTEXT_PACKAGE;
27@@ -7,4 +7,5 @@
28 public const string CONFIG_FILE;
29 public const string PKGDATADIR;
30 public const string INDICATORDIR;
31+ public const string GSD_BINARY;
32 }
33
34=== modified file 'src/settings-daemon.vala'
35--- src/settings-daemon.vala 2012-09-10 15:38:59 +0000
36+++ src/settings-daemon.vala 2013-01-30 20:36:25 +0000
37@@ -79,22 +79,13 @@
38
39 private async void run ()
40 {
41- /* Activate g-s-d over dbus */
42 try
43 {
44- var proxy = new GLib.DBusProxy.for_bus_sync (GLib.BusType.SESSION,
45- GLib.DBusProxyFlags.NONE, null,
46- "org.gnome.SettingsDaemon",
47- "/org/gnome/SettingsDaemon",
48- "org.gnome.SettingsDaemon",
49- null);
50-
51- /* This tells g-s-d to activate its plugins */
52- yield proxy.call ("Awake", null, GLib.DBusCallFlags.NONE, -1, null);
53+ Process.spawn_command_line_async (Config.GSD_BINARY);
54 }
55- catch (Error e)
56+ catch (SpawnError e)
57 {
58- debug ("Could not start gnome-settings-daemon over DBus: %s", e.message);
59+ debug ("Could not start gnome-settings-daemon: %s", e.message);
60 }
61 }
62 }

Subscribers

People subscribed via source and target branches