[mutter/wip/carlosg/frames-client: 3/12] x11: Fix size delta calculations




commit 0daa5bec1402722f5f630767c4b1661fa2c2e74b
Author: Carlos Garnacho <carlosg gnome org>
Date:   Fri Jun 10 15:36:39 2022 +0200

    x11: Fix size delta calculations
    
    This used to be a comparison between old/new width and height, but
    broke long ago.
    
    Fixes: 6e06648f - window: Refactor all move/resize operations to be in frame rect space

 src/x11/window-x11.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/x11/window-x11.c b/src/x11/window-x11.c
index 54d5da275d..ca794c439c 100644
--- a/src/x11/window-x11.c
+++ b/src/x11/window-x11.c
@@ -1297,8 +1297,8 @@ meta_window_x11_move_resize_internal (MetaWindow                *window,
 
   meta_frame_calc_borders (window->frame, &borders);
 
-  size_dx = constrained_rect.x - window->rect.width;
-  size_dy = constrained_rect.y - window->rect.height;
+  size_dx = constrained_rect.width - window->rect.width;
+  size_dy = constrained_rect.height - window->rect.height;
 
   window->rect = constrained_rect;
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]