mirror of
https://github.com/swaywm/sway.git
synced 2024-12-28 07:56:31 +01:00
Fix redundant call to seat_send_focus()
This commit fix calling to seat_send_focus() twice when a view is closed. This codes revert #2580, but the original issue nolonger exists.
This commit is contained in:
parent
b34c198f0b
commit
0b9feb6f39
1 changed files with 5 additions and 2 deletions
|
@ -288,8 +288,11 @@ static void handle_seat_node_destroy(struct wl_listener *listener, void *data) {
|
|||
}
|
||||
// The structure change might have caused it to move up to the top of
|
||||
// the focus stack without sending focus notifications to the view
|
||||
seat_send_focus(next_focus, seat);
|
||||
seat_set_focus(seat, next_focus);
|
||||
if (seat_get_focus(seat) == next_focus) {
|
||||
seat_send_focus(next_focus, seat);
|
||||
} else {
|
||||
seat_set_focus(seat, next_focus);
|
||||
}
|
||||
} else {
|
||||
// Setting focus_inactive
|
||||
focus = seat_get_focus_inactive(seat, &root->node);
|
||||
|
|
Loading…
Reference in a new issue