[gtk/master.win32: 4/6] gdksurface-win32.c: Fix resizing
- From: Chun-wei Fan <fanchunwei src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/master.win32: 4/6] gdksurface-win32.c: Fix resizing
- Date: Wed, 5 Aug 2020 08:03:10 +0000 (UTC)
commit 0df82cfd61f3ed6225c5f1eda05ec37f532bd31c
Author: Chun-wei Fan <fanchunwei src gnome org>
Date: Wed Aug 5 15:14:44 2020 +0800
gdksurface-win32.c: Fix resizing
Use gdk_surface_get_geometry() to get the correct x and y coordinates of the
window that we are resizing, so that the window does not reposition itself
automatically at the top-left corner at resizing as we to used hard-code the x
and y coordinates to 0.
gdk/win32/gdksurface-win32.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gdk/win32/gdksurface-win32.c b/gdk/win32/gdksurface-win32.c
index 097de39554..0bd57297ab 100644
--- a/gdk/win32/gdksurface-win32.c
+++ b/gdk/win32/gdksurface-win32.c
@@ -217,7 +217,7 @@ _gdk_win32_get_window_client_area_rect (GdkSurface *window,
{
int x, y, width, height;
- x = y = 0;
+ gdk_surface_get_geometry (window, &x, &y, NULL, NULL);
width = gdk_surface_get_width (window);
height = gdk_surface_get_height (window);
rect->left = x * scale;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]