[gtk+] wayland: Move some code around
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] wayland: Move some code around
- Date: Mon, 10 Mar 2014 17:41:30 +0000 (UTC)
commit 05b8609f8089981f168e694051ffcdc3fc3de086
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Mon Mar 10 13:31:53 2014 -0400
wayland: Move some code around
gdk/wayland/gdkwindow-wayland.c | 49 +++++++++++++++++---------------------
1 files changed, 22 insertions(+), 27 deletions(-)
---
diff --git a/gdk/wayland/gdkwindow-wayland.c b/gdk/wayland/gdkwindow-wayland.c
index dc63efc..a19261a 100644
--- a/gdk/wayland/gdkwindow-wayland.c
+++ b/gdk/wayland/gdkwindow-wayland.c
@@ -1071,7 +1071,28 @@ static const struct xdg_popup_listener xdg_popup_listener = {
static void
gdk_wayland_window_offset (GdkWindow *window,
gint *x_out,
- gint *y_out);
+ gint *y_out)
+{
+ GdkWindowImplWayland *impl, *parent_impl;
+ GdkWindow *parent_window;
+ gint x_offset = 0, y_offset = 0;
+
+ impl = GDK_WINDOW_IMPL_WAYLAND (window->impl);
+
+ parent_window = impl->transient_for;
+ while (parent_window)
+ {
+ parent_impl = GDK_WINDOW_IMPL_WAYLAND (parent_window->impl);
+
+ x_offset += window->x;
+ y_offset += window->y;
+
+ parent_window = parent_impl->transient_for;
+ }
+
+ *x_out = x_offset;
+ *y_out = y_offset;
+}
static void
gdk_wayland_window_create_xdg_popup (GdkWindow *window,
@@ -1376,32 +1397,6 @@ gdk_window_wayland_get_geometry (GdkWindow *window,
}
static void
-gdk_wayland_window_offset (GdkWindow *window,
- gint *x_out,
- gint *y_out)
-{
- GdkWindowImplWayland *impl, *parent_impl;
- GdkWindow *parent_window;
- gint x_offset = 0, y_offset = 0;
-
- impl = GDK_WINDOW_IMPL_WAYLAND (window->impl);
-
- parent_window = impl->transient_for;
- while (parent_window)
- {
- parent_impl = GDK_WINDOW_IMPL_WAYLAND (parent_window->impl);
-
- x_offset += window->x;
- y_offset += window->y;
-
- parent_window = parent_impl->transient_for;
- }
-
- *x_out = x_offset;
- *y_out = y_offset;
-}
-
-static void
gdk_window_wayland_get_root_coords (GdkWindow *window,
gint x,
gint y,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]