From 47f188360bd406d084935be0de209d69a7cec9e8 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Mon, 22 Sep 2014 14:35:51 -0500 Subject: Get the value on whether we should show on the welcome screen --- src/im-accounts-service.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/im-accounts-service.c b/src/im-accounts-service.c index cea5866..c7d3083 100644 --- a/src/im-accounts-service.c +++ b/src/im-accounts-service.c @@ -165,6 +165,20 @@ im_accounts_service_set_draws_attention (ImAccountsService * service, gboolean d gboolean im_accounts_service_get_show_on_greeter (ImAccountsService * service) { + g_return_val_if_fail(IM_IS_ACCOUNTS_SERVICE(service), FALSE); - return FALSE; + ImAccountsServicePrivate * priv = IM_ACCOUNTS_SERVICE_GET_PRIVATE(service); + + if (priv->touch_settings == NULL) { + return FALSE; + } + + GVariant * val = g_dbus_proxy_get_cached_property(priv->touch_settings, "MessagesWelcomeScreen"); + if (val == NULL) { + return FALSE; + } + + gboolean retval = g_variant_get_boolean(val); + g_variant_unref(val); + return retval; } -- cgit v1.2.3