[gdm] slave: don't save root windows anymore



commit d4c7cd5c88c11c07fa3e5152d61066d8777917c3
Author: Ray Strode <rstrode redhat com>
Date:   Wed Feb 20 12:58:45 2013 -0500

    slave: don't save root windows anymore
    
    GDM currently saves a screenshot to a pixmap and puts its
    XID in the _XROOTPMAP_ID root window property.
    
    It does this because gnome-settings-daemon used to use the
    _XROOTPMAP_ID to figure out a start frame to crossfade from.
    
    g-s-d doesn't do that anymore, all background handling is
    now down by gnome-shell, and gnome-shell does its own
    screenshotting.
    
    This commit strips that functionality from gdm.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=694291

 daemon/gdm-simple-slave.c |    8 -----
 daemon/gdm-slave.c        |   71 ---------------------------------------------
 daemon/gdm-slave.h        |    1 -
 3 files changed, 0 insertions(+), 80 deletions(-)
---
diff --git a/daemon/gdm-simple-slave.c b/daemon/gdm-simple-slave.c
index 00aabbc..6405672 100644
--- a/daemon/gdm-simple-slave.c
+++ b/daemon/gdm-simple-slave.c
@@ -986,14 +986,6 @@ setup_server (GdmSimpleSlave *slave)
         /* Put cursor out of the way on first head */
         gdm_slave_set_initial_cursor_position (GDM_SLAVE (slave));
 
-        /* The root window has a background that may be useful
-         * to cross fade or transition from when setting the
-         * login screen background.  We read it here, and stuff
-         * it into the standard _XROOTPMAP_ID root window property,
-         * so gnome-settings-daemon can get at it.
-         */
-        gdm_slave_save_root_windows (GDM_SLAVE (slave));
-
 #ifdef WITH_PLYMOUTH
         /* Plymouth is waiting for the go-ahead to exit */
         if (slave->priv->plymouth_is_running) {
diff --git a/daemon/gdm-slave.c b/daemon/gdm-slave.c
index 91ccbce..9474772 100644
--- a/daemon/gdm-slave.c
+++ b/daemon/gdm-slave.c
@@ -373,77 +373,6 @@ gdm_slave_run_script (GdmSlave   *slave,
         return ret;
 }
 
-static void
-gdm_slave_save_root_window_of_screen (GdmSlave *slave,
-                                      Atom      id_atom,
-                                      int       screen_number)
-{
-        Window root_window;
-        GC gc;
-        XGCValues values;
-        Pixmap pixmap;
-        int width, height, depth;
-
-        root_window = RootWindow (slave->priv->server_display,
-                                  screen_number);
-
-        width = DisplayWidth (slave->priv->server_display, screen_number);
-        height = DisplayHeight (slave->priv->server_display, screen_number);
-        depth = DefaultDepth (slave->priv->server_display, screen_number);
-        pixmap = XCreatePixmap (slave->priv->server_display,
-                                root_window,
-                                width, height, depth);
-
-        values.function = GXcopy;
-        values.plane_mask = AllPlanes;
-        values.fill_style = FillSolid;
-        values.subwindow_mode = IncludeInferiors;
-
-        gc = XCreateGC (slave->priv->server_display,
-                        root_window,
-                        GCFunction | GCPlaneMask | GCFillStyle | GCSubwindowMode,
-                        &values);
-
-        if (XCopyArea (slave->priv->server_display,
-                       root_window, pixmap, gc, 0, 0,
-                       width, height, 0, 0)) {
-
-                long pixmap_as_long;
-
-                pixmap_as_long = (long) pixmap;
-
-                XChangeProperty (slave->priv->server_display,
-                                 root_window, id_atom, XA_PIXMAP,
-                                 32, PropModeReplace, (guchar *) &pixmap_as_long,
-                                 1);
-
-        }
-
-        XFreeGC (slave->priv->server_display, gc);
-}
-
-void
-gdm_slave_save_root_windows (GdmSlave *slave)
-{
-        int i, number_of_screens;
-        Atom atom;
-
-        number_of_screens = ScreenCount (slave->priv->server_display);
-
-        atom = XInternAtom (slave->priv->server_display,
-                            "_XROOTPMAP_ID", False);
-
-        if (atom == 0) {
-                return;
-        }
-
-        for (i = 0; i < number_of_screens; i++) {
-                gdm_slave_save_root_window_of_screen (slave, atom, i);
-        }
-
-        XSync (slave->priv->server_display, False);
-}
-
 static XRRScreenResources *
 get_screen_resources (Display *dpy)
 {
diff --git a/daemon/gdm-slave.h b/daemon/gdm-slave.h
index 10f31e2..902de21 100644
--- a/daemon/gdm-slave.h
+++ b/daemon/gdm-slave.h
@@ -106,7 +106,6 @@ gboolean            gdm_slave_connect_to_x11_display (GdmSlave   *slave);
 
 void                gdm_slave_set_initial_cursor_position (GdmSlave *slave);
 
-void                gdm_slave_save_root_windows      (GdmSlave   *slave);
 gboolean            gdm_slave_run_script             (GdmSlave   *slave,
                                                       const char *dir,
                                                       const char *username);


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