2008-04-05 16:49:35 +00:00
|
|
|
diff -up gnome-settings-daemon-2.22.1/plugins/xrandr/gsd-xrandr-manager.c.add-randr-12 gnome-settings-daemon-2.22.1/plugins/xrandr/gsd-xrandr-manager.c
|
2008-03-26 15:13:00 +00:00
|
|
|
--- gnome-settings-daemon-2.22.1/plugins/xrandr/gsd-xrandr-manager.c.add-randr-12 2008-03-24 17:21:50.000000000 -0400
|
2008-04-05 16:49:35 +00:00
|
|
|
+++ gnome-settings-daemon-2.22.1/plugins/xrandr/gsd-xrandr-manager.c 2008-04-05 12:42:41.000000000 -0400
|
|
|
|
@@ -35,15 +35,33 @@
|
2008-03-02 22:42:21 +00:00
|
|
|
#include <gdk/gdk.h>
|
2008-02-12 19:57:10 +00:00
|
|
|
#include <gdk/gdkx.h>
|
|
|
|
#include <gtk/gtk.h>
|
2008-03-02 22:42:21 +00:00
|
|
|
-#include <gconf/gconf-client.h>
|
|
|
|
+
|
2008-02-12 19:57:10 +00:00
|
|
|
+#define I_KNOW_THIS_IS_UNSTABLE_AND_ONLY_IN_FEDORA
|
|
|
|
+#include <libgnomeui/monitor-db.h>
|
|
|
|
+#include <libgnomeui/randrwrap.h>
|
2008-03-02 22:42:21 +00:00
|
|
|
|
2008-02-12 19:57:10 +00:00
|
|
|
#ifdef HAVE_RANDR
|
|
|
|
#include <X11/extensions/Xrandr.h>
|
2008-04-05 16:49:35 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
-#include "gnome-settings-profile.h"
|
2008-03-02 22:42:21 +00:00
|
|
|
#include "gsd-xrandr-manager.h"
|
2008-03-02 22:21:35 +00:00
|
|
|
|
2008-03-02 22:42:21 +00:00
|
|
|
+#define GSD_XRANDR_MANAGER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GSD_TYPE_XRANDR_MANAGER, GsdXrandrManagerPrivate))
|
|
|
|
+
|
2008-03-02 22:21:35 +00:00
|
|
|
+#define VIDEO_KEYSYM "XF86Display"
|
|
|
|
+
|
2008-03-02 22:42:21 +00:00
|
|
|
+struct GsdXrandrManagerPrivate
|
|
|
|
+{
|
2008-03-02 22:21:35 +00:00
|
|
|
+ /* Key code of the fn-F7 video key (XF86Display) */
|
|
|
|
+ guint keycode;
|
|
|
|
+ RWScreen *rw_screen;
|
|
|
|
+ gboolean running;
|
2008-03-02 22:42:21 +00:00
|
|
|
+};
|
|
|
|
+
|
|
|
|
+enum {
|
|
|
|
+ PROP_0,
|
|
|
|
+};
|
|
|
|
+
|
|
|
|
static void gsd_xrandr_manager_class_init (GsdXrandrManagerClass *klass);
|
|
|
|
static void gsd_xrandr_manager_init (GsdXrandrManager *xrandr_manager);
|
|
|
|
static void gsd_xrandr_manager_finalize (GObject *object);
|
2008-04-05 16:49:35 +00:00
|
|
|
@@ -52,252 +70,74 @@ G_DEFINE_TYPE (GsdXrandrManager, gsd_xra
|
2008-02-12 19:57:10 +00:00
|
|
|
|
|
|
|
static gpointer manager_object = NULL;
|
|
|
|
|
|
|
|
-#ifdef HAVE_RANDR
|
|
|
|
-static int
|
|
|
|
-get_rotation (GConfClient *client,
|
|
|
|
- char *display,
|
|
|
|
- int screen)
|
|
|
|
-{
|
|
|
|
- char *key;
|
|
|
|
- int val;
|
|
|
|
- GError *error;
|
|
|
|
-
|
|
|
|
- key = g_strdup_printf ("%s/%d/rotation", display, screen);
|
|
|
|
- error = NULL;
|
|
|
|
- val = gconf_client_get_int (client, key, &error);
|
|
|
|
- g_free (key);
|
|
|
|
-
|
|
|
|
- if (error == NULL) {
|
|
|
|
- return val;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- g_error_free (error);
|
|
|
|
-
|
|
|
|
- return 0;
|
2008-03-02 22:21:35 +00:00
|
|
|
+static GdkAtom
|
|
|
|
+gnome_randr_atom (void)
|
|
|
|
+{
|
|
|
|
+ return gdk_atom_intern ("_GNOME_RANDR_ATOM", FALSE);
|
|
|
|
}
|
|
|
|
|
2008-02-12 19:57:10 +00:00
|
|
|
-static int
|
|
|
|
-get_resolution (GConfClient *client,
|
|
|
|
- int screen,
|
|
|
|
- char *keys[],
|
|
|
|
- int *width,
|
|
|
|
- int *height)
|
|
|
|
-{
|
|
|
|
- int i;
|
|
|
|
- char *key;
|
|
|
|
- char *val;
|
|
|
|
- int w;
|
|
|
|
- int h;
|
|
|
|
-
|
|
|
|
- val = NULL;
|
|
|
|
- for (i = 0; keys[i] != NULL; i++) {
|
|
|
|
- key = g_strdup_printf ("%s/%d/resolution", keys[i], screen);
|
|
|
|
- val = gconf_client_get_string (client, key, NULL);
|
|
|
|
- g_free (key);
|
|
|
|
-
|
|
|
|
- if (val != NULL) {
|
|
|
|
- break;
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- if (val == NULL) {
|
|
|
|
- return -1;
|
|
|
|
- }
|
2008-04-05 16:49:35 +00:00
|
|
|
+static Atom
|
|
|
|
+gnome_randr_xatom (void)
|
|
|
|
+{
|
|
|
|
+ return gdk_x11_atom_to_xatom (gnome_randr_atom());
|
|
|
|
+}
|
|
|
|
|
2008-02-12 19:57:10 +00:00
|
|
|
- if (sscanf (val, "%dx%d", &w, &h) != 2) {
|
|
|
|
- g_free (val);
|
|
|
|
- return -1;
|
2008-04-05 16:49:35 +00:00
|
|
|
+static GdkFilterReturn
|
|
|
|
+on_client_message (GdkXEvent *xevent,
|
|
|
|
+ GdkEvent *event,
|
|
|
|
+ gpointer data)
|
|
|
|
+{
|
|
|
|
+ RWScreen *screen = data;
|
|
|
|
+ XEvent *ev = (XEvent *)xevent;
|
|
|
|
+
|
|
|
|
+ if (ev->type == ClientMessage &&
|
|
|
|
+ ev->xclient.message_type == gnome_randr_xatom()) {
|
|
|
|
+
|
|
|
|
+ configuration_apply_stored (screen);
|
|
|
|
+
|
|
|
|
+ return GDK_FILTER_REMOVE;
|
|
|
|
}
|
2008-02-12 19:57:10 +00:00
|
|
|
-
|
|
|
|
- g_free (val);
|
|
|
|
-
|
|
|
|
- *width = w;
|
|
|
|
- *height = h;
|
|
|
|
-
|
|
|
|
- return i;
|
2008-04-05 16:49:35 +00:00
|
|
|
+
|
|
|
|
+ /* Pass the event on to GTK+ */
|
|
|
|
+ return GDK_FILTER_CONTINUE;
|
2008-02-12 19:57:10 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
-static int
|
|
|
|
-get_rate (GConfClient *client,
|
|
|
|
- char *display,
|
|
|
|
- int screen)
|
2008-03-02 22:21:35 +00:00
|
|
|
+static GdkFilterReturn
|
2008-04-05 16:49:35 +00:00
|
|
|
+event_filter (GdkXEvent *xevent,
|
|
|
|
+ GdkEvent *event,
|
|
|
|
+ gpointer data)
|
2008-02-12 19:57:10 +00:00
|
|
|
{
|
|
|
|
- char *key;
|
|
|
|
- int val;
|
|
|
|
- GError *error;
|
2008-04-05 16:49:35 +00:00
|
|
|
+ GsdXrandrManager *manager = data;
|
|
|
|
+ XEvent *xev = (XEvent *) xevent;
|
2008-03-02 22:42:21 +00:00
|
|
|
|
2008-02-12 19:57:10 +00:00
|
|
|
- key = g_strdup_printf ("%s/%d/rate", display, screen);
|
|
|
|
- error = NULL;
|
|
|
|
- val = gconf_client_get_int (client, key, &error);
|
|
|
|
- g_free (key);
|
2008-04-05 16:49:35 +00:00
|
|
|
+ if (!manager->priv->running)
|
|
|
|
+ return GDK_FILTER_CONTINUE;
|
2008-03-02 22:21:35 +00:00
|
|
|
|
2008-02-12 19:57:10 +00:00
|
|
|
- if (error == NULL) {
|
|
|
|
- return val;
|
|
|
|
- }
|
|
|
|
-
|
2008-03-02 22:42:21 +00:00
|
|
|
- g_error_free (error);
|
2008-04-05 16:49:35 +00:00
|
|
|
+ /* verify we have a key event */
|
|
|
|
+ if (xev->xany.type != KeyPress && xev->xany.type != KeyRelease)
|
|
|
|
+ return GDK_FILTER_CONTINUE;
|
2008-02-12 19:57:10 +00:00
|
|
|
|
2008-03-02 22:42:21 +00:00
|
|
|
- return 0;
|
|
|
|
-}
|
|
|
|
-
|
2008-02-12 19:57:10 +00:00
|
|
|
-static int
|
|
|
|
-find_closest_size (XRRScreenSize *sizes,
|
|
|
|
- int nsizes,
|
|
|
|
- int width,
|
|
|
|
- int height)
|
|
|
|
-{
|
|
|
|
- int closest;
|
|
|
|
- int closest_width;
|
|
|
|
- int closest_height;
|
|
|
|
- int i;
|
|
|
|
-
|
|
|
|
- closest = 0;
|
|
|
|
- closest_width = sizes[0].width;
|
|
|
|
- closest_height = sizes[0].height;
|
|
|
|
- for (i = 1; i < nsizes; i++) {
|
|
|
|
- if (ABS (sizes[i].width - width) < ABS (closest_width - width) ||
|
|
|
|
- (sizes[i].width == closest_width &&
|
|
|
|
- ABS (sizes[i].height - height) < ABS (closest_height - height))) {
|
|
|
|
- closest = i;
|
|
|
|
- closest_width = sizes[i].width;
|
|
|
|
- closest_height = sizes[i].height;
|
|
|
|
- }
|
2008-04-05 16:49:35 +00:00
|
|
|
+ if (xev->xkey.keycode == manager->priv->keycode) {
|
|
|
|
+ /* FIXME: here we should cycle between valid
|
|
|
|
+ * configurations, and save them
|
|
|
|
+ */
|
|
|
|
+ configuration_apply_stored (manager->priv->rw_screen);
|
|
|
|
+
|
|
|
|
+ return GDK_FILTER_CONTINUE;
|
2008-02-12 19:57:10 +00:00
|
|
|
}
|
2008-03-02 22:21:35 +00:00
|
|
|
|
2008-02-12 19:57:10 +00:00
|
|
|
- return closest;
|
|
|
|
+ return GDK_FILTER_CONTINUE;
|
|
|
|
}
|
|
|
|
-#endif /* HAVE_RANDR */
|
|
|
|
|
2008-04-05 16:49:35 +00:00
|
|
|
static void
|
2008-02-12 19:57:10 +00:00
|
|
|
-apply_settings (GsdXrandrManager *manager)
|
2008-04-05 16:49:35 +00:00
|
|
|
+on_randr_event (RWScreen *screen, gpointer data)
|
2008-02-12 19:57:10 +00:00
|
|
|
{
|
|
|
|
-#ifdef HAVE_RANDR
|
|
|
|
- GdkDisplay *display;
|
|
|
|
- Display *xdisplay;
|
|
|
|
- int major;
|
|
|
|
- int minor;
|
|
|
|
- int event_base;
|
|
|
|
- int error_base;
|
|
|
|
- GConfClient *client;
|
|
|
|
- int n_screens;
|
|
|
|
- GdkScreen *screen;
|
|
|
|
- GdkWindow *root_window;
|
|
|
|
- int width;
|
|
|
|
- int height;
|
|
|
|
- int rate;
|
|
|
|
- int rotation;
|
|
|
|
-#ifdef HOST_NAME_MAX
|
|
|
|
- char hostname[HOST_NAME_MAX + 1];
|
|
|
|
-#else
|
|
|
|
- char hostname[256];
|
|
|
|
-#endif
|
|
|
|
- char *specific_path;
|
|
|
|
- char *keys[3];
|
|
|
|
- int i;
|
|
|
|
- int residx;
|
|
|
|
-
|
2008-03-26 15:13:00 +00:00
|
|
|
- gnome_settings_profile_start (NULL);
|
|
|
|
-
|
2008-02-12 19:57:10 +00:00
|
|
|
- display = gdk_display_get_default ();
|
|
|
|
- xdisplay = gdk_x11_display_get_xdisplay (display);
|
|
|
|
-
|
|
|
|
- /* Check if XRandR is supported on the display */
|
|
|
|
- if (!XRRQueryExtension (xdisplay, &event_base, &error_base)
|
|
|
|
- || XRRQueryVersion (xdisplay, &major, &minor) == 0) {
|
2008-03-26 15:13:00 +00:00
|
|
|
- goto out;
|
2008-02-12 19:57:10 +00:00
|
|
|
- }
|
2008-03-26 15:13:00 +00:00
|
|
|
-
|
2008-02-12 19:57:10 +00:00
|
|
|
- if (major != 1 || minor < 1) {
|
|
|
|
- g_message ("Display has unsupported version of XRandR (%d.%d), not setting resolution.", major, minor);
|
2008-03-26 15:13:00 +00:00
|
|
|
- goto out;
|
2008-02-12 19:57:10 +00:00
|
|
|
- }
|
2008-04-05 16:49:35 +00:00
|
|
|
-
|
2008-02-12 19:57:10 +00:00
|
|
|
- client = gconf_client_get_default ();
|
2008-04-05 16:49:35 +00:00
|
|
|
-
|
2008-02-12 19:57:10 +00:00
|
|
|
- i = 0;
|
|
|
|
- specific_path = NULL;
|
|
|
|
- if (gethostname (hostname, sizeof (hostname)) == 0) {
|
|
|
|
- specific_path = g_strconcat ("/desktop/gnome/screen/", hostname, NULL);
|
|
|
|
- keys[i++] = specific_path;
|
|
|
|
- }
|
|
|
|
- keys[i++] = "/desktop/gnome/screen/default";
|
|
|
|
- keys[i++] = NULL;
|
2008-04-05 16:49:35 +00:00
|
|
|
-
|
2008-02-12 19:57:10 +00:00
|
|
|
- n_screens = gdk_display_get_n_screens (display);
|
|
|
|
- for (i = 0; i < n_screens; i++) {
|
|
|
|
- screen = gdk_display_get_screen (display, i);
|
|
|
|
- root_window = gdk_screen_get_root_window (screen);
|
|
|
|
- residx = get_resolution (client, i, keys, &width, &height);
|
|
|
|
-
|
|
|
|
- if (residx != -1) {
|
|
|
|
- XRRScreenSize *sizes;
|
|
|
|
- int nsizes;
|
|
|
|
- int j;
|
|
|
|
- int closest;
|
|
|
|
- short *rates;
|
|
|
|
- int nrates;
|
|
|
|
- int status;
|
|
|
|
- int current_size;
|
|
|
|
- short current_rate;
|
|
|
|
- XRRScreenConfiguration *config;
|
|
|
|
- Rotation current_rotation;
|
|
|
|
-
|
|
|
|
- config = XRRGetScreenInfo (xdisplay, gdk_x11_drawable_get_xid (GDK_DRAWABLE (root_window)));
|
|
|
|
-
|
|
|
|
- rate = get_rate (client, keys[residx], i);
|
|
|
|
-
|
|
|
|
- sizes = XRRConfigSizes (config, &nsizes);
|
|
|
|
- closest = find_closest_size (sizes, nsizes, width, height);
|
|
|
|
-
|
|
|
|
- rates = XRRConfigRates (config, closest, &nrates);
|
|
|
|
- for (j = 0; j < nrates; j++) {
|
|
|
|
- if (rates[j] == rate)
|
|
|
|
- break;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- /* Rate not supported, let X pick */
|
|
|
|
- if (j == nrates)
|
|
|
|
- rate = 0;
|
|
|
|
-
|
|
|
|
- rotation = get_rotation (client, keys[residx], i);
|
|
|
|
- if (rotation == 0)
|
|
|
|
- rotation = RR_Rotate_0;
|
|
|
|
-
|
|
|
|
- current_size = XRRConfigCurrentConfiguration (config, ¤t_rotation);
|
|
|
|
- current_rate = XRRConfigCurrentRate (config);
|
|
|
|
-
|
|
|
|
- if (closest != current_size ||
|
|
|
|
- rate != current_rate ||
|
|
|
|
- rotation != current_rotation) {
|
|
|
|
- status = XRRSetScreenConfigAndRate (xdisplay,
|
|
|
|
- config,
|
|
|
|
- gdk_x11_drawable_get_xid (GDK_DRAWABLE (root_window)),
|
|
|
|
- closest,
|
|
|
|
- (Rotation) rotation,
|
|
|
|
- rate,
|
|
|
|
- GDK_CURRENT_TIME);
|
|
|
|
- }
|
2008-04-05 16:49:35 +00:00
|
|
|
-
|
2008-02-12 19:57:10 +00:00
|
|
|
- XRRFreeScreenConfigInfo (config);
|
|
|
|
- }
|
2008-04-05 16:49:35 +00:00
|
|
|
- }
|
|
|
|
+ GsdXrandrManager *manager = data;
|
2008-03-26 15:13:00 +00:00
|
|
|
|
2008-02-12 19:57:10 +00:00
|
|
|
- g_free (specific_path);
|
|
|
|
-
|
|
|
|
- /* We need to make sure we process the screen resize event. */
|
|
|
|
- gdk_display_sync (display);
|
2008-04-05 16:49:35 +00:00
|
|
|
-
|
2008-02-12 19:57:10 +00:00
|
|
|
- while (gtk_events_pending ()) {
|
|
|
|
- gtk_main_iteration ();
|
|
|
|
- }
|
2008-04-05 16:49:35 +00:00
|
|
|
-
|
2008-02-12 19:57:10 +00:00
|
|
|
- if (client != NULL) {
|
|
|
|
- g_object_unref (client);
|
|
|
|
- }
|
2008-03-26 15:13:00 +00:00
|
|
|
- out:
|
|
|
|
- gnome_settings_profile_end (NULL);
|
2008-04-05 16:49:35 +00:00
|
|
|
-
|
|
|
|
-#endif /* HAVE_RANDR */
|
2008-03-26 15:13:00 +00:00
|
|
|
+ if (!manager->priv->running)
|
|
|
|
+ return;
|
2008-04-05 16:49:35 +00:00
|
|
|
+
|
2008-02-12 19:57:10 +00:00
|
|
|
+ /* FIXME: Set up any new screens here */
|
|
|
|
}
|
|
|
|
|
|
|
|
gboolean
|
2008-04-05 16:49:35 +00:00
|
|
|
@@ -306,8 +146,30 @@ gsd_xrandr_manager_start (GsdXrandrManag
|
2008-02-12 19:57:10 +00:00
|
|
|
{
|
|
|
|
g_debug ("Starting xrandr manager");
|
|
|
|
|
|
|
|
- apply_settings (manager);
|
2008-04-05 16:49:35 +00:00
|
|
|
-
|
2008-03-02 22:21:35 +00:00
|
|
|
+ manager->priv->running = TRUE;
|
2008-04-05 16:49:35 +00:00
|
|
|
+
|
2008-03-02 22:21:35 +00:00
|
|
|
+ if (manager->priv->keycode) {
|
2008-04-05 16:49:35 +00:00
|
|
|
+ gdk_error_trap_push ();
|
|
|
|
+
|
2008-03-02 22:21:35 +00:00
|
|
|
+ XGrabKey (gdk_x11_get_default_xdisplay(),
|
|
|
|
+ manager->priv->keycode, AnyModifier,
|
|
|
|
+ gdk_x11_get_default_root_xwindow(),
|
|
|
|
+ True, GrabModeAsync, GrabModeAsync);
|
2008-03-26 15:13:00 +00:00
|
|
|
+
|
2008-04-05 16:49:35 +00:00
|
|
|
+ gdk_flush ();
|
|
|
|
+ gdk_error_trap_pop ();
|
|
|
|
+ }
|
|
|
|
+
|
2008-03-02 22:21:35 +00:00
|
|
|
+ configuration_apply_stored (manager->priv->rw_screen);
|
2008-04-05 16:49:35 +00:00
|
|
|
+
|
2008-03-02 22:21:35 +00:00
|
|
|
+ gdk_window_add_filter (gdk_get_default_root_window(),
|
|
|
|
+ (GdkFilterFunc)event_filter,
|
|
|
|
+ manager);
|
2008-04-05 16:49:35 +00:00
|
|
|
+
|
2008-02-12 19:57:10 +00:00
|
|
|
+ gdk_add_client_message_filter (gnome_randr_atom(),
|
|
|
|
+ on_client_message,
|
2008-03-02 22:21:35 +00:00
|
|
|
+ manager->priv->rw_screen);
|
2008-04-05 16:49:35 +00:00
|
|
|
+
|
2008-02-12 19:57:10 +00:00
|
|
|
return TRUE;
|
|
|
|
}
|
2008-04-05 16:49:35 +00:00
|
|
|
|
|
|
|
@@ -315,6 +177,16 @@ void
|
2008-03-02 22:21:35 +00:00
|
|
|
gsd_xrandr_manager_stop (GsdXrandrManager *manager)
|
|
|
|
{
|
|
|
|
g_debug ("Stopping xrandr manager");
|
|
|
|
+
|
|
|
|
+ manager->priv->running = FALSE;
|
2008-04-05 16:49:35 +00:00
|
|
|
+
|
|
|
|
+ gdk_error_trap_push ();
|
|
|
|
+
|
2008-03-02 22:21:35 +00:00
|
|
|
+ XUngrabKey (gdk_x11_get_default_xdisplay(),
|
|
|
|
+ manager->priv->keycode, AnyModifier,
|
|
|
|
+ gdk_x11_get_default_root_xwindow());
|
2008-04-05 16:49:35 +00:00
|
|
|
+
|
|
|
|
+ gdk_error_trap_pop ();
|
2008-03-02 22:21:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
2008-04-05 16:49:35 +00:00
|
|
|
@@ -388,11 +260,22 @@ gsd_xrandr_manager_class_init (GsdXrandr
|
2008-03-02 22:42:21 +00:00
|
|
|
object_class->constructor = gsd_xrandr_manager_constructor;
|
|
|
|
object_class->dispose = gsd_xrandr_manager_dispose;
|
|
|
|
object_class->finalize = gsd_xrandr_manager_finalize;
|
|
|
|
+
|
|
|
|
+ g_type_class_add_private (klass, sizeof (GsdXrandrManagerPrivate));
|
|
|
|
}
|
|
|
|
|
2008-03-02 22:21:35 +00:00
|
|
|
static void
|
|
|
|
gsd_xrandr_manager_init (GsdXrandrManager *manager)
|
|
|
|
{
|
|
|
|
+ Display *dpy = gdk_x11_get_default_xdisplay ();
|
|
|
|
+ guint keyval = gdk_keyval_from_name (VIDEO_KEYSYM);
|
|
|
|
+ guint keycode = XKeysymToKeycode (dpy, keyval);
|
2008-04-05 16:49:35 +00:00
|
|
|
+
|
2008-03-02 22:42:21 +00:00
|
|
|
+ manager->priv = GSD_XRANDR_MANAGER_GET_PRIVATE (manager);
|
|
|
|
+
|
2008-03-02 22:21:35 +00:00
|
|
|
+ manager->priv->keycode = keycode;
|
|
|
|
+ manager->priv->rw_screen = rw_screen_new (
|
|
|
|
+ gdk_screen_get_default(), on_randr_event, NULL);
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
2008-04-05 16:49:35 +00:00
|
|
|
@@ -405,6 +288,8 @@ gsd_xrandr_manager_finalize (GObject *ob
|
2008-03-02 22:42:21 +00:00
|
|
|
|
|
|
|
xrandr_manager = GSD_XRANDR_MANAGER (object);
|
|
|
|
|
|
|
|
+ g_return_if_fail (xrandr_manager->priv != NULL);
|
|
|
|
+
|
|
|
|
G_OBJECT_CLASS (gsd_xrandr_manager_parent_class)->finalize (object);
|
|
|
|
}
|
|
|
|
|