From e72f86265018f3616510e0fda6f71bb13e92598b Mon Sep 17 00:00:00 2001 From: Sumandora Date: Fri, 27 Jun 2025 13:30:30 +0200 Subject: [PATCH] src/workspaces.c: allow dragged views to be moved to other workspaces --- src/workspaces.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/workspaces.c b/src/workspaces.c index 2ce1f376..45b2f918 100644 --- a/src/workspaces.c +++ b/src/workspaces.c @@ -443,6 +443,11 @@ workspaces_switch_to(struct workspace *target, bool update_focus) /* Make sure new views will spawn on the new workspace */ server->workspaces.current = target; + struct view *grabbed_view = server->grabbed_view; + if (grabbed_view && !view_is_always_on_top(grabbed_view)) { + view_move_to_workspace(grabbed_view, target); + } + /* * Make sure we are focusing what the user sees. Only refocus if * the focus is not already on an omnipresent or always-on-top view. -- 2.52.0