diff options
-rw-r--r-- | .gitignore | 5 | ||||
-rw-r--r-- | Makefile.am | 1 | ||||
-rw-r--r-- | configure.ac | 2 | ||||
-rw-r--r-- | data/Makefile.am | 15 | ||||
-rw-r--r-- | data/im.telepathy.MissionControl.FromEmpathy.gschema.xml | 18 | ||||
-rw-r--r-- | src/connectivity-monitor.c | 2 | ||||
-rw-r--r-- | src/kludge-transport.c | 8 | ||||
-rw-r--r-- | tests/twisted/tools/exec-with-log.sh.in | 6 |
8 files changed, 53 insertions, 4 deletions
@@ -11,6 +11,8 @@ *.gcda *.gcno *.gcov +/data/*.valid +/data/gschemas.compiled /doc/reference/*/html /doc/reference/*/xml /doc/reference/*/*-decl-list.txt @@ -51,8 +53,6 @@ install-sh /lcov.html /lcov.info /lcov.info.tmp -libmcclient.pc -libmcclient/diff libtool ltmain.sh /m4/gtk-doc.m4 @@ -76,6 +76,7 @@ TAGS /telepathy-mission-control-5* /tests/account-store /tests/keyring-command +/tests/tease-the-minotaur /tests/test-* tests/mc-client tests/twisted/with-session-bus-*.dbus-monitor-logs diff --git a/Makefile.am b/Makefile.am index 34e12451..d5af95c3 100644 --- a/Makefile.am +++ b/Makefile.am @@ -7,6 +7,7 @@ CHECK_FOR_UNRELEASED := \ $(NULL) SUBDIRS = \ + data \ m4 \ tools \ xml \ diff --git a/configure.ac b/configure.ac index e26c8809..b8420de5 100644 --- a/configure.ac +++ b/configure.ac @@ -413,12 +413,14 @@ GLIB_MKENUMS="`$PKG_CONFIG --variable=glib_mkenums glib-2.0`" AC_SUBST(GLIB_MKENUMS) GTK_DOC_CHECK([1.17],[--flavour no-tmpl]) +GLIB_GSETTINGS pluginlibdir=$libdir/mission-control AC_SUBST(pluginlibdir) AC_OUTPUT([ Makefile \ +data/Makefile \ doc/Makefile \ doc/reference/Makefile \ doc/reference/mission-control-plugins/Makefile \ diff --git a/data/Makefile.am b/data/Makefile.am new file mode 100644 index 00000000..3d293bd8 --- /dev/null +++ b/data/Makefile.am @@ -0,0 +1,15 @@ +gsettings_SCHEMAS = \ + im.telepathy.MissionControl.FromEmpathy.gschema.xml \ + $(NULL) +@GSETTINGS_RULES@ + +# We build our own schema cache here for the benefit of the test suite +noinst_DATA = gschemas.compiled +gschemas.compiled: $(gsettings_SCHEMAS) + $(AM_V_GEN)$(GLIB_COMPILE_SCHEMAS) --targetdir=$(builddir) $(srcdir) + +EXTRA_DIST = \ + $(gsettings_SCHEMAS) \ + $(NULL) + +CLEANFILES = $(noinst_DATA) diff --git a/data/im.telepathy.MissionControl.FromEmpathy.gschema.xml b/data/im.telepathy.MissionControl.FromEmpathy.gschema.xml new file mode 100644 index 00000000..ad5f595a --- /dev/null +++ b/data/im.telepathy.MissionControl.FromEmpathy.gschema.xml @@ -0,0 +1,18 @@ +<schemalist> + + <enum id="position"> + <value nick="top-left" value="1"/> + <value nick="top-right" value="2"/> + <value nick="bottom-left" value="3"/> + <value nick="bottom-right" value="4"/> + </enum> + + <!-- sic: we are aliasing dconf key paths from Empathy's schema --> + <schema id="im.telepathy.MissionControl.FromEmpathy" path="/org/gnome/empathy/"> + <key name="use-conn" type="b"> + <default>true</default> + <summary>Connectivity managers should be used</summary> + <description>Whether connectivity managers should be used to automatically disconnect/reconnect.</description> + </key> + </schema> +</schemalist> diff --git a/src/connectivity-monitor.c b/src/connectivity-monitor.c index 2c94e3f6..0ab8272e 100644 --- a/src/connectivity-monitor.c +++ b/src/connectivity-monitor.c @@ -485,7 +485,7 @@ mcd_connectivity_monitor_set_use_conn (McdConnectivityMonitor *connectivity_moni if (use_conn == priv->use_conn) return; - DEBUG ("use_conn GSetting key changed; new value = %s", + DEBUG ("use-conn GSettings key changed; new value = %s", use_conn ? "true" : "false"); priv->use_conn = use_conn; diff --git a/src/kludge-transport.c b/src/kludge-transport.c index 67d5b234..bdd80b81 100644 --- a/src/kludge-transport.c +++ b/src/kludge-transport.c @@ -41,6 +41,9 @@ struct _McdKludgeTransportPrivate { /* Hold a set of McdAccounts which would like to go online. */ GHashTable *pending_accounts; + + /* Application settings we steal from under Empathy's nose. */ + GSettings *settings; }; static void transport_iface_init ( @@ -82,6 +85,10 @@ mcd_kludge_transport_constructed (GObject *object) priv->pending_accounts = g_hash_table_new_full (NULL, NULL, g_object_unref, NULL); + + priv->settings = g_settings_new ("im.telepathy.MissionControl.FromEmpathy"); + g_settings_bind (priv->settings, "use-conn", priv->minotaur, "use-conn", + G_SETTINGS_BIND_GET); } static void @@ -92,6 +99,7 @@ mcd_kludge_transport_dispose (GObject *object) GObjectClass *parent_class = mcd_kludge_transport_parent_class; tp_clear_object (&priv->minotaur); + tp_clear_object (&priv->settings); g_list_free (priv->transports); priv->transports = NULL; diff --git a/tests/twisted/tools/exec-with-log.sh.in b/tests/twisted/tools/exec-with-log.sh.in index 84b13ea2..a7abbf91 100644 --- a/tests/twisted/tools/exec-with-log.sh.in +++ b/tests/twisted/tools/exec-with-log.sh.in @@ -51,7 +51,8 @@ elif test -n "$MISSIONCONTROL_TEST_REFDBG"; then fi # The bus-daemon that is activating us doesn't know it's also the system bus -export DBUS_SYSTEM_BUS_ADDRESS="$DBUS_SESSION_BUS_ADDRESS" +DBUS_SYSTEM_BUS_ADDRESS="$DBUS_SESSION_BUS_ADDRESS" +export DBUS_SYSTEM_BUS_ADDRESS if test "z$MC_EXECUTABLE" = z; then MC_EXECUTABLE=@abs_top_builddir@/tests/twisted/mc-debug-server @@ -63,6 +64,9 @@ if test -f "$MC_ACCOUNT_DIR/gnome-keyring-env"; then export GNOME_KEYRING_CONTROL GNOME_KEYRING_PID MC_KEYRING_NAME SSH_AUTH_SOCK fi +GSETTINGS_SCHEMA_DIR=@abs_top_builddir@/data +export GSETTINGS_SCHEMA_DIR + exec @abs_top_builddir@/libtool --mode=execute \ $MISSIONCONTROL_WRAPPER \ $MC_EXECUTABLE |