aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Kirill Primak <vyivel@posteo.net>2021-09-18 11:29:03 +0300
committerLibravatar Simon Ser <contact@emersion.fr>2021-09-23 21:32:56 +0200
commitb7b3ef6dcf904fce8ff072a88e505765a44a4ec6 (patch)
treebdc78e33eeb7e4e523beea25f111bd77f2a89bac
parentxdg-shell: remove unused request_maximize listener (diff)
downloadsway-b7b3ef6dcf904fce8ff072a88e505765a44a4ec6.tar.gz
sway-b7b3ef6dcf904fce8ff072a88e505765a44a4ec6.tar.zst
sway-b7b3ef6dcf904fce8ff072a88e505765a44a4ec6.zip
layer-shell: chase wlr layer surface refactor
-rw-r--r--sway/desktop/layer_shell.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/sway/desktop/layer_shell.c b/sway/desktop/layer_shell.c
index 47bb07bd..67369fb3 100644
--- a/sway/desktop/layer_shell.c
+++ b/sway/desktop/layer_shell.c
@@ -598,14 +598,14 @@ void handle_layer_shell_surface(struct wl_listener *listener, void *data) {
598 sway_log(SWAY_DEBUG, "new layer surface: namespace %s layer %d anchor %" PRIu32 598 sway_log(SWAY_DEBUG, "new layer surface: namespace %s layer %d anchor %" PRIu32
599 " size %" PRIu32 "x%" PRIu32 " margin %" PRIu32 ",%" PRIu32 ",%" PRIu32 ",%" PRIu32 ",", 599 " size %" PRIu32 "x%" PRIu32 " margin %" PRIu32 ",%" PRIu32 ",%" PRIu32 ",%" PRIu32 ",",
600 layer_surface->namespace, 600 layer_surface->namespace,
601 layer_surface->client_pending.layer, 601 layer_surface->pending.layer,
602 layer_surface->client_pending.anchor, 602 layer_surface->pending.anchor,
603 layer_surface->client_pending.desired_width, 603 layer_surface->pending.desired_width,
604 layer_surface->client_pending.desired_height, 604 layer_surface->pending.desired_height,
605 layer_surface->client_pending.margin.top, 605 layer_surface->pending.margin.top,
606 layer_surface->client_pending.margin.right, 606 layer_surface->pending.margin.right,
607 layer_surface->client_pending.margin.bottom, 607 layer_surface->pending.margin.bottom,
608 layer_surface->client_pending.margin.left); 608 layer_surface->pending.margin.left);
609 609
610 if (!layer_surface->output) { 610 if (!layer_surface->output) {
611 // Assign last active output 611 // Assign last active output
@@ -659,13 +659,13 @@ void handle_layer_shell_surface(struct wl_listener *listener, void *data) {
659 sway_layer->output_destroy.notify = handle_output_destroy; 659 sway_layer->output_destroy.notify = handle_output_destroy;
660 wl_signal_add(&output->events.destroy, &sway_layer->output_destroy); 660 wl_signal_add(&output->events.destroy, &sway_layer->output_destroy);
661 661
662 wl_list_insert(&output->layers[layer_surface->client_pending.layer], 662 wl_list_insert(&output->layers[layer_surface->pending.layer],
663 &sway_layer->link); 663 &sway_layer->link);
664 664
665 // Temporarily set the layer's current state to client_pending 665 // Temporarily set the layer's current state to pending
666 // So that we can easily arrange it 666 // So that we can easily arrange it
667 struct wlr_layer_surface_v1_state old_state = layer_surface->current; 667 struct wlr_layer_surface_v1_state old_state = layer_surface->current;
668 layer_surface->current = layer_surface->client_pending; 668 layer_surface->current = layer_surface->pending;
669 arrange_layers(output); 669 arrange_layers(output);
670 layer_surface->current = old_state; 670 layer_surface->current = old_state;
671} 671}