From bceff6da8d9770139f3cd335ff4331d2c905091d Mon Sep 17 00:00:00 2001 From: Thomas Adam Date: Tue, 12 Dec 2023 07:04:37 +0000 Subject: [PATCH] monitor: use g.max or g.normal directly When updating which monitor a window is on, don't call get_unshaded_geometry() as the window's coordinates are already relative to where it is. Instead, use either the maximized frame or the normal frame. Fixes #608 --- fvwm/update.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fvwm/update.c b/fvwm/update.c index 265beb5e5..556e1c8ea 100644 --- a/fvwm/update.c +++ b/fvwm/update.c @@ -667,7 +667,7 @@ Bool update_fvwm_monitor(FvwmWindow *fw) rectangle g; struct monitor *mnew; - get_unshaded_geometry(fw, &g); + g = IS_MAXIMIZED(fw) ? fw->g.max : fw->g.normal; mnew = FindScreenOfXY(g.x, g.y); /* Avoid unnecessary updates. */