Blob Blame History Raw
--- a/src/gs-window-x11.c
+++ b/src/gs-window-x11.c
@@ -2132,7 +2132,6 @@ on_clock_changed (GnomeWallClock *clock,
         update_clock (GS_WINDOW (user_data));
 }
 
-
 static gboolean
 shade_background (GtkWidget    *widget,
                cairo_t      *cr,
@@ -2140,11 +2139,16 @@ shade_background (GtkWidget    *widget,
 {
         cairo_set_source_rgba (cr, 0.0, 0.0, 0.0, 0.7);
         cairo_paint (cr);
-        gs_window_clear_to_background_surface (window);
-
         return FALSE;
 }
 
+static void
+on_realized (GtkWidget *widget, GSWindow *window)
+{
+    gs_window_clear_to_background_surface (window);
+    gtk_widget_queue_draw (widget);
+}
+
 void
 gs_window_set_away_message (GSWindow   *window,
                             const char *message)
@@ -2241,9 +2245,14 @@ gs_window_init (GSWindow *window)
         gtk_widget_set_halign (grid, GTK_ALIGN_CENTER);
         gtk_widget_set_hexpand (grid, TRUE);
         gtk_widget_set_vexpand (grid, TRUE);
-        
+
+        g_signal_connect (main_box,
+                          "realize",
+                          G_CALLBACK (on_realized),
+                          window);
+
         g_signal_connect (main_box, "draw", G_CALLBACK (shade_background), window);
-               
+
         create_info_bar (window);       
 }