[nautilus] Make sure the desktop window is transparent



commit 95be14bd5ec45f61c78a28108d7b071ebaaec378
Author: Matthias Clasen <mclasen redhat com>
Date:   Mon Aug 26 17:19:50 2013 -0400

    Make sure the desktop window is transparent
    
    The code was just assuming that setting an rgba visual is enough
    to make a window see-through. This assumption was invalidated
    by the GTK+ csd work that happened this cycle. We can fix this
    by explicitly setting the background color of the desktop
    window.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=706665

 src/nautilus-desktop-window.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/nautilus-desktop-window.c b/src/nautilus-desktop-window.c
index d99e9fb..3ea50bd 100644
--- a/src/nautilus-desktop-window.c
+++ b/src/nautilus-desktop-window.c
@@ -132,6 +132,7 @@ nautilus_desktop_window_new (GtkApplication *application,
 {
        NautilusDesktopWindow *window;
        int width_request, height_request;
+        GdkRGBA transparent = {0, 0, 0, 0};
 
        width_request = gdk_screen_get_width (screen);
        height_request = gdk_screen_get_height (screen);
@@ -151,6 +152,8 @@ nautilus_desktop_window_new (GtkApplication *application,
         * Note that nautilus_desktop_window_init is too early to do this.
         */
        nautilus_desktop_window_update_directory (window);
+        gtk_widget_override_background_color (GTK_WIDGET (window), 0, &transparent);
+
 
        return window;
 }


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