From aa292db8d1000785d743c41552d4a27e8a2f5595 Mon Sep 17 00:00:00 2001 From: "D.B" Date: Fri, 5 Aug 2016 10:43:54 +0200 Subject: Fix switch to prev ws on handle_view_created Switching back to original workspace should be done only if workspace was switched while appending new view. --- sway/handlers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sway/handlers.c b/sway/handlers.c index 6d35f8a2..846d0005 100644 --- a/sway/handlers.c +++ b/sway/handlers.c @@ -410,7 +410,7 @@ static bool handle_view_created(wlc_handle handle) { } wlc_view_set_mask(handle, VISIBLE); - if (return_to_workspace && current_ws) { + if (return_to_workspace && current_ws != swayc_active_workspace()) { // we were on one workspace, switched to another to add this view, // now let's return to where we were workspace_switch(current_ws); -- cgit v1.2.3-54-g00ecf