[gtk/gtk-3-24: 1/2] [gtk3] [x11] Fix coordinate space of rect in gdk_x11_window_get_frame_extents when called on popups.
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/gtk-3-24: 1/2] [gtk3] [x11] Fix coordinate space of rect in gdk_x11_window_get_frame_extents when called on popups.
- Date: Thu, 23 Jun 2022 12:00:15 +0000 (UTC)
commit c43e3c43396abcdbd6b0f6e2565f8563b52c5027
Author: Emilio Cobos Álvarez <emilio crisal io>
Date: Mon Jun 20 10:43:06 2022 +0200
[gtk3] [x11] Fix coordinate space of rect in gdk_x11_window_get_frame_extents when called on popups.
This is the same fix as !4820, but applied to the gtk 3 branch.
gdk/x11/gdkwindow-x11.c | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
---
diff --git a/gdk/x11/gdkwindow-x11.c b/gdk/x11/gdkwindow-x11.c
index 721d9bb63a..eb822e0989 100644
--- a/gdk/x11/gdkwindow-x11.c
+++ b/gdk/x11/gdkwindow-x11.c
@@ -3240,14 +3240,19 @@ gdk_x11_window_get_frame_extents (GdkWindow *window,
impl = GDK_WINDOW_IMPL_X11 (window->impl);
/* Refine our fallback answer a bit using local information */
- rect->x = window->x * impl->window_scale;
- rect->y = window->y * impl->window_scale;
- rect->width = window->width * impl->window_scale;
- rect->height = window->height * impl->window_scale;
+ rect->x = window->x;
+ rect->y = window->y;
+ rect->width = window->width;
+ rect->height = window->height;
if (GDK_WINDOW_DESTROYED (window) || impl->override_redirect)
return;
+ rect->x *= impl->window_scale;
+ rect->y *= impl->window_scale;
+ rect->width *= impl->window_scale;
+ rect->height *= impl->window_scale;
+
nvroots = 0;
vroots = NULL;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]