[gtk+/client-side-windows: 247/284] Don't set the background for input only window
- From: Alexander Larsson <alexl src gnome org>
- To: svn-commits-list gnome org
- Subject: [gtk+/client-side-windows: 247/284] Don't set the background for input only window
- Date: Thu, 2 Apr 2009 14:20:45 -0400 (EDT)
commit 50a5f6046d7973cd4834d724ab6d03b69706d028
Author: Alexander Larsson <alexl redhat com>
Date: Wed Feb 4 20:21:02 2009 +0100
Don't set the background for input only window
This is not allowed and will cause X errors.
---
gdk/gdkwindow.c | 17 ++++++++++++-----
1 files changed, 12 insertions(+), 5 deletions(-)
diff --git a/gdk/gdkwindow.c b/gdk/gdkwindow.c
index 8710153..4a2153d 100644
--- a/gdk/gdkwindow.c
+++ b/gdk/gdkwindow.c
@@ -1310,9 +1310,12 @@ gdk_window_set_has_native (GdkWindow *window, gboolean has_native)
reparent_to_impl (private);
- GDK_WINDOW_IMPL_GET_IFACE (private->impl)->set_background (window, &private->bg_color);
- if (private->bg_pixmap != NULL)
- GDK_WINDOW_IMPL_GET_IFACE (private->impl)->set_back_pixmap (window, private->bg_pixmap);
+ if (!private->input_only)
+ {
+ GDK_WINDOW_IMPL_GET_IFACE (private->impl)->set_background (window, &private->bg_color);
+ if (private->bg_pixmap != NULL)
+ GDK_WINDOW_IMPL_GET_IFACE (private->impl)->set_back_pixmap (window, private->bg_pixmap);
+ }
GDK_WINDOW_IMPL_GET_IFACE (private->impl)->input_shape_combine_region ((GdkWindow *)private, private->input_shape, 0, 0);
@@ -6502,7 +6505,9 @@ gdk_window_set_background (GdkWindow *window,
private->bg_pixmap = NULL;
- if (!GDK_WINDOW_DESTROYED (window) && gdk_window_has_impl (private))
+ if (!GDK_WINDOW_DESTROYED (window) &&
+ gdk_window_has_impl (private) &&
+ !private->input_only)
GDK_WINDOW_IMPL_GET_IFACE (private->impl)->set_background (window, &private->bg_color);
}
@@ -6563,7 +6568,9 @@ gdk_window_set_back_pixmap (GdkWindow *window,
else
private->bg_pixmap = GDK_NO_BG;
- if (!GDK_WINDOW_DESTROYED (window) && gdk_window_has_impl (private))
+ if (!GDK_WINDOW_DESTROYED (window) &&
+ gdk_window_has_impl (private) &&
+ !private->input_only)
GDK_WINDOW_IMPL_GET_IFACE (private->impl)->set_back_pixmap (window, private->bg_pixmap);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]