mirror of
https://github.com/gwenhael-le-moine/sway-patched-tray-menu.git
synced 2024-12-28 22:23:42 +01:00
handle_seat_node_destroy: do not focus own node
In handle_seat_node_destroy, it was possible to focus the node attached to the seat node that is being destroyed when an empty workspace was being destroyed in a multiple seat environment. This resulted in infinite recursion when attempting to destroy the workspace. This just moves the seat node destruction higher so it cannot be the focus inactive for the seat. This is the same ordering that is applied to destruction of seat nodes for containers
This commit is contained in:
parent
804aacb8c7
commit
3e33e1c76f
1 changed files with 1 additions and 1 deletions
|
@ -153,6 +153,7 @@ static void handle_seat_node_destroy(struct wl_listener *listener, void *data) {
|
|||
struct sway_node *focus = seat_get_focus(seat);
|
||||
|
||||
if (node->type == N_WORKSPACE) {
|
||||
seat_node_destroy(seat_node);
|
||||
// If an unmanaged or layer surface is focused when an output gets
|
||||
// disabled and an empty workspace on the output was focused by the
|
||||
// seat, the seat needs to refocus it's focus inactive to update the
|
||||
|
@ -166,7 +167,6 @@ static void handle_seat_node_destroy(struct wl_listener *listener, void *data) {
|
|||
seat->workspace = NULL;
|
||||
}
|
||||
}
|
||||
seat_node_destroy(seat_node);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue