[gtk+] x11: Remove mentions of GDK_WINDOW_ROOT
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] x11: Remove mentions of GDK_WINDOW_ROOT
- Date: Mon, 13 Nov 2017 21:48:36 +0000 (UTC)
commit 5f73afae3d8d108d05619cce0426da06cd02f77f
Author: Matthias Clasen <mclasen redhat com>
Date: Mon Nov 13 16:47:50 2017 -0500
x11: Remove mentions of GDK_WINDOW_ROOT
This backend never creates a window of this type, so no
need to check for it anymore.
gdk/x11/gdkdisplay-x11.c | 12 ++----------
gdk/x11/gdkwindow-x11.c | 3 +--
2 files changed, 3 insertions(+), 12 deletions(-)
---
diff --git a/gdk/x11/gdkdisplay-x11.c b/gdk/x11/gdkdisplay-x11.c
index e2dd382..5a560d6 100644
--- a/gdk/x11/gdkdisplay-x11.c
+++ b/gdk/x11/gdkdisplay-x11.c
@@ -924,15 +924,8 @@ gdk_x11_display_translate_event (GdkEventTranslator *translator,
: xevent->xconfigure.event != xevent->xconfigure.window
? " (discarding substructure)"
: ""));
- if (window && GDK_WINDOW_TYPE (window) == GDK_WINDOW_ROOT)
+ if (_gdk_x11_display_is_root_window (display, xevent->xconfigure.window))
{
- window_impl->unscaled_width = xevent->xconfigure.width;
- window_impl->unscaled_height = xevent->xconfigure.height;
- window->width = (xevent->xconfigure.width + window_impl->window_scale - 1) /
window_impl->window_scale;
- window->height = (xevent->xconfigure.height + window_impl->window_scale - 1) /
window_impl->window_scale;
-
- _gdk_window_update_size (window);
- _gdk_x11_window_update_size (window_impl);
_gdk_x11_screen_size_changed (screen, xevent);
}
@@ -947,8 +940,7 @@ gdk_x11_display_translate_event (GdkEventTranslator *translator,
if (!window ||
xevent->xconfigure.event != xevent->xconfigure.window ||
- GDK_WINDOW_TYPE (window) == GDK_WINDOW_CHILD ||
- GDK_WINDOW_TYPE (window) == GDK_WINDOW_ROOT)
+ GDK_WINDOW_TYPE (window) == GDK_WINDOW_CHILD)
return_val = FALSE;
else
{
diff --git a/gdk/x11/gdkwindow-x11.c b/gdk/x11/gdkwindow-x11.c
index 2371ce5..c91ef8e 100644
--- a/gdk/x11/gdkwindow-x11.c
+++ b/gdk/x11/gdkwindow-x11.c
@@ -902,7 +902,7 @@ _gdk_x11_display_create_window_impl (GdkDisplay *display,
{
case GDK_WINDOW_TOPLEVEL:
case GDK_WINDOW_TEMP:
- if (window->parent && GDK_WINDOW_TYPE (window->parent) != GDK_WINDOW_ROOT)
+ if (window->parent)
{
/* The common code warns for this case */
xparent = GDK_SCREEN_XROOTWIN (x11_screen);
@@ -1484,7 +1484,6 @@ gdk_window_x11_hide (GdkWindow *window)
return;
case GDK_WINDOW_FOREIGN:
- case GDK_WINDOW_ROOT:
case GDK_WINDOW_CHILD:
default:
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]