[gnome-settings-daemon] color: Use the GnomeRRScreen singleton



commit 4cb1515ebaa635e7686d153eba977a206b256514
Author: Rodrigo Moya <rodrigo gnome-db org>
Date:   Thu Sep 22 10:19:20 2011 +0200

    color: Use the GnomeRRScreen singleton

 plugins/color/gsd-color-manager.c   |    2 +-
 plugins/power/gsd-power-manager.c   |    2 +-
 plugins/xrandr/gsd-xrandr-manager.c |    3 ++-
 3 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/plugins/color/gsd-color-manager.c b/plugins/color/gsd-color-manager.c
index 6b0561a..a310875 100644
--- a/plugins/color/gsd-color-manager.c
+++ b/plugins/color/gsd-color-manager.c
@@ -1433,7 +1433,7 @@ gsd_color_manager_start (GsdColorManager *manager,
         gnome_settings_profile_start (NULL);
 
         /* coldplug the list of screens */
-        priv->x11_screen = gnome_rr_screen_new (gdk_screen_get_default (), error);
+        priv->x11_screen = gnome_settings_session_get_screen (error);
         if (priv->x11_screen == NULL)
                 goto out;
 
diff --git a/plugins/power/gsd-power-manager.c b/plugins/power/gsd-power-manager.c
index 0a730bc..57d0b27 100644
--- a/plugins/power/gsd-power-manager.c
+++ b/plugins/power/gsd-power-manager.c
@@ -3397,7 +3397,7 @@ gsd_power_manager_start (GsdPowerManager *manager,
                           G_CALLBACK (idle_idletime_alarm_expired_cb), manager);
 
         /* coldplug the list of screens */
-        manager->priv->x11_screen = gnome_rr_screen_new (gdk_screen_get_default (), error);
+        manager->priv->x11_screen = gnome_settings_session_get_screen (error);
         if (manager->priv->x11_screen == NULL)
                 return FALSE;
 
diff --git a/plugins/xrandr/gsd-xrandr-manager.c b/plugins/xrandr/gsd-xrandr-manager.c
index 7f0fe0b..9536ac9 100644
--- a/plugins/xrandr/gsd-xrandr-manager.c
+++ b/plugins/xrandr/gsd-xrandr-manager.c
@@ -48,6 +48,7 @@
 #include "gsd-enums.h"
 #include "gsd-input-helper.h"
 #include "gnome-settings-profile.h"
+#include "gnome-settings-session.h"
 #include "gsd-xrandr-manager.h"
 
 #define GSD_XRANDR_MANAGER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GSD_TYPE_XRANDR_MANAGER, GsdXrandrManagerPrivate))
@@ -1860,7 +1861,7 @@ gsd_xrandr_manager_start (GsdXrandrManager *manager,
         log_open ();
         log_msg ("------------------------------------------------------------\nSTARTING XRANDR PLUGIN\n");
 
-        manager->priv->rw_screen = gnome_rr_screen_new (gdk_screen_get_default (), error);
+        manager->priv->rw_screen = gnome_settings_session_get_screen (error);
 
         if (manager->priv->rw_screen == NULL) {
                 log_msg ("Could not initialize the RANDR plugin%s%s\n",



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]