summaryrefslogtreecommitdiffstats
path: root/sway/input/seat.c
diff options
context:
space:
mode:
authorLibravatar Ryan Dwyer <ryandwyer1@gmail.com>2018-07-26 18:36:46 +1000
committerLibravatar Ryan Dwyer <ryandwyer1@gmail.com>2018-07-28 22:41:04 +1000
commit08cfba2192f5770d975c5fe70789a81aaee4dc7e (patch)
tree7f07e32020649ae5c049e8533f0cf040dc80e166 /sway/input/seat.c
parentMerge pull request #2372 from RyanDwyer/fix-use-after-free-v2 (diff)
downloadsway-08cfba2192f5770d975c5fe70789a81aaee4dc7e.tar.gz
sway-08cfba2192f5770d975c5fe70789a81aaee4dc7e.tar.zst
sway-08cfba2192f5770d975c5fe70789a81aaee4dc7e.zip
Allow containers to float
Things worth noting: * When a fullscreen view unmaps, the check to unset fullscreen on the workspace has been moved out of view_unmap and into container_destroy, because containers can be fullscreen too * The calls to `container_reap_empty_recursive(workspace)` have been removed from `container_set_floating`. That function reaps upwards so it wouldn't do anything. I'm probably the one who originally added it... * My fix (b14bd1b0b1536039e4f46fe94515c7c44e7afc61) for the tabbed child crash has a side effect where when you close a floating container, focus is not given to the tiled container again. I've removed my fix and removed the call to `send_cursor_motion` from `seat_set_focus_warp`. We should consider calling it from somewhere earlier in the call stack.
Diffstat (limited to 'sway/input/seat.c')
-rw-r--r--sway/input/seat.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c
index e7b6e0c5..877a93c6 100644
--- a/sway/input/seat.c
+++ b/sway/input/seat.c
@@ -184,7 +184,6 @@ static void handle_seat_container_destroy(struct wl_listener *listener,
184 bool set_focus = 184 bool set_focus =
185 focus != NULL && 185 focus != NULL &&
186 (focus == con || container_has_child(con, focus)) && 186 (focus == con || container_has_child(con, focus)) &&
187 con->parent && con->parent->children->length > 1 &&
188 con->type != C_WORKSPACE; 187 con->type != C_WORKSPACE;
189 188
190 seat_container_destroy(seat_con); 189 seat_container_destroy(seat_con);
@@ -754,10 +753,6 @@ void seat_set_focus_warp(struct sway_seat *seat,
754 } 753 }
755 } 754 }
756 755
757 if (last_focus != NULL) {
758 cursor_send_pointer_motion(seat->cursor, 0, true);
759 }
760
761 seat->has_focus = (container != NULL); 756 seat->has_focus = (container != NULL);
762 757
763 update_debug_tree(); 758 update_debug_tree();