diff options
author | Kirill Primak <vyivel@eclair.cafe> | 2023-03-05 23:49:45 +0300 |
---|---|---|
committer | Simon Ser <contact@emersion.fr> | 2023-06-02 20:11:42 +0200 |
commit | c9e1dab3187d22ada0232d699e759a628e0ed185 (patch) | |
tree | 2838a14e3144fca71a7c693cd36ced33bf622bf7 /sway/input/seat.c | |
parent | xwayland: don't rely on event source being data (diff) | |
download | sway-c9e1dab3187d22ada0232d699e759a628e0ed185.tar.gz sway-c9e1dab3187d22ada0232d699e759a628e0ed185.tar.zst sway-c9e1dab3187d22ada0232d699e759a628e0ed185.zip |
chore: chase wlroots map logic unification
Diffstat (limited to 'sway/input/seat.c')
-rw-r--r-- | sway/input/seat.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c index bcb89b48..5795f40f 100644 --- a/sway/input/seat.c +++ b/sway/input/seat.c | |||
@@ -367,7 +367,7 @@ static void handle_new_node(struct wl_listener *listener, void *data) { | |||
367 | } | 367 | } |
368 | 368 | ||
369 | static void drag_icon_damage_whole(struct sway_drag_icon *icon) { | 369 | static void drag_icon_damage_whole(struct sway_drag_icon *icon) { |
370 | if (!icon->wlr_drag_icon->mapped) { | 370 | if (!icon->wlr_drag_icon->surface->mapped) { |
371 | return; | 371 | return; |
372 | } | 372 | } |
373 | desktop_damage_surface(icon->wlr_drag_icon->surface, icon->x, icon->y, true); | 373 | desktop_damage_surface(icon->wlr_drag_icon->surface, icon->x, icon->y, true); |
@@ -511,9 +511,9 @@ static void handle_start_drag(struct wl_listener *listener, void *data) { | |||
511 | icon->surface_commit.notify = drag_icon_handle_surface_commit; | 511 | icon->surface_commit.notify = drag_icon_handle_surface_commit; |
512 | wl_signal_add(&wlr_drag_icon->surface->events.commit, &icon->surface_commit); | 512 | wl_signal_add(&wlr_drag_icon->surface->events.commit, &icon->surface_commit); |
513 | icon->unmap.notify = drag_icon_handle_unmap; | 513 | icon->unmap.notify = drag_icon_handle_unmap; |
514 | wl_signal_add(&wlr_drag_icon->events.unmap, &icon->unmap); | 514 | wl_signal_add(&wlr_drag_icon->surface->events.unmap, &icon->unmap); |
515 | icon->map.notify = drag_icon_handle_map; | 515 | icon->map.notify = drag_icon_handle_map; |
516 | wl_signal_add(&wlr_drag_icon->events.map, &icon->map); | 516 | wl_signal_add(&wlr_drag_icon->surface->events.map, &icon->map); |
517 | icon->destroy.notify = drag_icon_handle_destroy; | 517 | icon->destroy.notify = drag_icon_handle_destroy; |
518 | wl_signal_add(&wlr_drag_icon->events.destroy, &icon->destroy); | 518 | wl_signal_add(&wlr_drag_icon->events.destroy, &icon->destroy); |
519 | 519 | ||
@@ -1350,7 +1350,7 @@ void seat_set_focus_layer(struct sway_seat *seat, | |||
1350 | } else if (!layer || seat->focused_layer == layer) { | 1350 | } else if (!layer || seat->focused_layer == layer) { |
1351 | return; | 1351 | return; |
1352 | } | 1352 | } |
1353 | assert(layer->mapped); | 1353 | assert(layer->surface->mapped); |
1354 | seat_set_focus_surface(seat, layer->surface, true); | 1354 | seat_set_focus_surface(seat, layer->surface, true); |
1355 | if (layer->current.layer >= ZWLR_LAYER_SHELL_V1_LAYER_TOP) { | 1355 | if (layer->current.layer >= ZWLR_LAYER_SHELL_V1_LAYER_TOP) { |
1356 | seat->focused_layer = layer; | 1356 | seat->focused_layer = layer; |