From 9cc16182d31850c0b4180b29dc915c6dfc5ff7e8 Mon Sep 17 00:00:00 2001 From: "Torrance, Douglas" Date: Fri, 20 Jan 2023 02:45:56 +0000 Subject: [PATCH] Use dock to determine whether drawer is on right side when swapping Previously, we assumed that it always switched from left to right or vice versa when calling swapDrawer. However, now we may also call swapDrawer when changing the value of "KeepDockOnPrimaryHead", which wouldn't actually switch which side of the screen it's on. So instead, we determine which side of the screen it should be on based on the dock. --- src/dock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dock.c b/src/dock.c index 30504121..a0c4f2dd 100644 --- a/src/dock.c +++ b/src/dock.c @@ -4610,7 +4610,7 @@ static void swapDrawer(WDock *drawer, int new_x) { int i; - drawer->on_right_side = !drawer->on_right_side; + drawer->on_right_side = drawer->screen_ptr->dock->on_right_side; drawer->x_pos = new_x; for (i = 0; i < drawer->max_icons; i++) {