Merge pull request #2580 from RyanDwyer/fix-focus-after-fullscreen

Restore focus correctly when closing a fullscreen view
This commit is contained in:
Drew DeVault 2018-09-05 20:39:13 -04:00 committed by GitHub
commit 85e95d5825
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -168,13 +168,10 @@ 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 structure change might have caused it to move up to the top of
// the focus stack without sending focus notifications to the view // the focus stack without sending focus notifications to the view
if (seat_get_focus(seat) == next_focus) {
seat_send_focus(next_focus, seat); seat_send_focus(next_focus, seat);
} else {
seat_set_focus(seat, next_focus); seat_set_focus(seat, next_focus);
} }
} }
}
static struct sway_seat_node *seat_node_from_node( static struct sway_seat_node *seat_node_from_node(
struct sway_seat *seat, struct sway_node *node) { struct sway_seat *seat, struct sway_node *node) {