[gnome-settings-daemon] background: Listen for "draw-background" changing
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-settings-daemon] background: Listen for "draw-background" changing
- Date: Fri, 11 Mar 2011 19:30:09 +0000 (UTC)
commit 8fab983bb557e0b242616884afab9f049ee1931f
Author: Bastien Nocera <hadess hadess net>
Date: Fri Mar 11 18:51:31 2011 +0000
background: Listen for "draw-background" changing
Do the right thing when "draw-background" is set to TRUE again,
and do draw the background (hopefully).
plugins/background/gsd-background-manager.c | 11 +++++++++++
1 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/plugins/background/gsd-background-manager.c b/plugins/background/gsd-background-manager.c
index 40697a2..1837d5a 100644
--- a/plugins/background/gsd-background-manager.c
+++ b/plugins/background/gsd-background-manager.c
@@ -427,6 +427,15 @@ connect_screen_signals (GsdBackgroundManager *manager)
}
}
+static void
+draw_background_changed (GSettings *settings,
+ const char *key,
+ GsdBackgroundManager *manager)
+{
+ if (dont_draw_background (manager) == FALSE)
+ queue_timeout (manager);
+}
+
gboolean
gsd_background_manager_start (GsdBackgroundManager *manager,
GError **error)
@@ -437,6 +446,8 @@ gsd_background_manager_start (GsdBackgroundManager *manager,
gnome_settings_profile_start (NULL);
manager->priv->settings = g_settings_new ("org.gnome.desktop.background");
+ g_signal_connect (manager->priv->settings, "changed::draw-background",
+ G_CALLBACK (draw_background_changed), manager);
/* If this is set, nautilus will draw the background and is
* almost definitely in our session. however, it may not be
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]