1 From 254b9a4c540e3dff1dcd17db2ceea6a9fa5df973 Mon Sep 17 00:00:00 2001
2 From: Benjamin Otte <otte@redhat.com>
3 Date: Thu, 09 Jun 2011 04:29:45 +0000
4 Subject: gdk: Make background changes queue a repaint
6 For client-side windows, we need to queue a repaint when the background
7 changes. For native windows, the windowing system does take care of it,
8 but client-side windows are our own, so we gotta do it manually.
10 https://bugzilla.gnome.org/show_bug.cgi?id=652102
12 diff --git a/gdk/gdkwindow.c b/gdk/gdkwindow.c
13 index f058570..10d83ab 100644
16 @@ -8004,11 +8004,15 @@ gdk_window_set_background (GdkWindow *window,
19 if (!GDK_WINDOW_DESTROYED (window) &&
20 - gdk_window_has_impl (private) &&
23 - impl_iface = GDK_WINDOW_IMPL_GET_IFACE (private->impl);
24 - impl_iface->set_background (window, &private->bg_color);
25 + if (gdk_window_has_impl (private))
27 + impl_iface = GDK_WINDOW_IMPL_GET_IFACE (private->impl);
28 + impl_iface->set_background (window, &private->bg_color);
31 + gdk_window_invalidate_rect_full (window, NULL, TRUE, CLEAR_BG_ALL);
35 @@ -8077,11 +8081,15 @@ gdk_window_set_back_pixmap (GdkWindow *window,
36 private->bg_pixmap = GDK_NO_BG;
38 if (!GDK_WINDOW_DESTROYED (window) &&
39 - gdk_window_has_impl (private) &&
42 - impl_iface = GDK_WINDOW_IMPL_GET_IFACE (private->impl);
43 - impl_iface->set_back_pixmap (window, private->bg_pixmap);
44 + if (gdk_window_has_impl (private))
46 + impl_iface = GDK_WINDOW_IMPL_GET_IFACE (private->impl);
47 + impl_iface->set_back_pixmap (window, private->bg_pixmap);
50 + gdk_window_invalidate_rect_full (window, NULL, TRUE, CLEAR_BG_ALL);