diff options
author | Drew DeVault <sir@cmpwn.com> | 2018-03-30 13:31:52 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-03-30 13:31:52 -0400 |
commit | 1c50d79e1940d9dce6217d0ca19611a19709120a (patch) | |
tree | 9326e417bd348c79dfe0def12ed8ecaa51656ddb | |
parent | Merge pull request #1659 from swaywm/default-orientation (diff) | |
parent | Add xwayland views to focused container (diff) | |
download | sway-1c50d79e1940d9dce6217d0ca19611a19709120a.tar.gz sway-1c50d79e1940d9dce6217d0ca19611a19709120a.tar.zst sway-1c50d79e1940d9dce6217d0ca19611a19709120a.zip |
Merge pull request #1664 from swaywm/xwayland-add-to-focused
Add xwayland views to focused container
-rw-r--r-- | sway/desktop/xwayland.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/sway/desktop/xwayland.c b/sway/desktop/xwayland.c index d608c8b6..3e08b20e 100644 --- a/sway/desktop/xwayland.c +++ b/sway/desktop/xwayland.c | |||
@@ -154,12 +154,10 @@ static void handle_map_notify(struct wl_listener *listener, void *data) { | |||
154 | struct sway_view *view = sway_surface->view; | 154 | struct sway_view *view = sway_surface->view; |
155 | container_view_destroy(view->swayc); | 155 | container_view_destroy(view->swayc); |
156 | 156 | ||
157 | struct sway_container *parent = root_container.children->items[0]; | 157 | struct sway_seat *seat = input_manager_current_seat(input_manager); |
158 | parent = parent->children->items[0]; // workspace | 158 | struct sway_container *focus = sway_seat_get_focus_inactive(seat, &root_container); |
159 | 159 | struct sway_container *cont = container_view_create(focus, view); | |
160 | struct sway_container *cont = container_view_create(parent, view); | ||
161 | view->swayc = cont; | 160 | view->swayc = cont; |
162 | |||
163 | arrange_windows(cont->parent, -1, -1); | 161 | arrange_windows(cont->parent, -1, -1); |
164 | sway_input_manager_set_focus(input_manager, cont); | 162 | sway_input_manager_set_focus(input_manager, cont); |
165 | } | 163 | } |