From 26d26391da4d38236c7767b6f3601c0b4852c786 Mon Sep 17 00:00:00 2001 From: Ettore Perazzoli Date: Tue, 18 Sep 2001 18:48:36 +0000 Subject: Use ->bin_window [instead of ->window] if the widget is a GtkLayout. * e-gtk-utils.c (widget_realize_callback_for_backing_store): Use ->bin_window [instead of ->window] if the widget is a GtkLayout. svn path=/trunk/; revision=12943 --- e-util/e-gtk-utils.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'e-util/e-gtk-utils.c') diff --git a/e-util/e-gtk-utils.c b/e-util/e-gtk-utils.c index 564d834cfb..f865dabf8d 100644 --- a/e-util/e-gtk-utils.c +++ b/e-util/e-gtk-utils.c @@ -26,7 +26,9 @@ #include #endif +#include #include +#include #include @@ -119,10 +121,15 @@ widget_realize_callback_for_backing_store (GtkWidget *widget, void *data) { XSetWindowAttributes attributes; + GdkWindow *window; + + if (GTK_IS_LAYOUT (widget)) + window = GTK_LAYOUT (widget)->bin_window; + else + window = widget->window; attributes.backing_store = Always; - XChangeWindowAttributes (GDK_WINDOW_XDISPLAY (widget->window), - GDK_WINDOW_XWINDOW (widget->window), + XChangeWindowAttributes (GDK_WINDOW_XDISPLAY (window), GDK_WINDOW_XWINDOW (window), CWBackingStore, &attributes); } -- cgit v1.2.3