aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMykyta Holubakha <hilobakho@gmail.com>2016-06-27 21:36:27 +0300
committerMykyta Holubakha <hilobakho@gmail.com>2016-07-15 00:22:53 +0300
commita2bb2801724d9404529617f1b2b300033e2a8c8b (patch)
tree8e208e260a704564f6f0c3af0b0865d58d60829d
parent136387144cdcaa65c693fb4ffeed437bdd85235f (diff)
downloadsway-a2bb2801724d9404529617f1b2b300033e2a8c8b.tar.xz
Spawn new views to target ws's focused container
-rw-r--r--sway/handlers.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sway/handlers.c b/sway/handlers.c
index 647f9771..e322c579 100644
--- a/sway/handlers.c
+++ b/sway/handlers.c
@@ -226,8 +226,8 @@ static bool handle_view_created(wlc_handle handle) {
// using newview as a temp storage location here,
// rather than adding yet another workspace var
newview = workspace_for_pid(pid);
- if (newview && newview != current_ws) {
- focused = newview;
+ if (newview) {
+ focused = get_focused_container(newview);
return_to_workspace = true;
}
newview = NULL;