diff options
author | Kirill Primak <vyivel@eclair.cafe> | 2022-11-12 12:58:48 +0300 |
---|---|---|
committer | Simon Ser <contact@emersion.fr> | 2022-11-12 11:50:04 +0100 |
commit | 85005b52fe5b832e4ea914fa28048b0c5c803769 (patch) | |
tree | 49166ff04126bf199f50325a8c82f7231c814f87 | |
parent | workspace_create: Don't allow NULL name (diff) | |
download | sway-85005b52fe5b832e4ea914fa28048b0c5c803769.tar.gz sway-85005b52fe5b832e4ea914fa28048b0c5c803769.tar.zst sway-85005b52fe5b832e4ea914fa28048b0c5c803769.zip |
output: set damage ring bounds to pixel values
Fixes: https://github.com/swaywm/sway/issues/7254
-rw-r--r-- | sway/desktop/output.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sway/desktop/output.c b/sway/desktop/output.c index 75651a7a..81a20e25 100644 --- a/sway/desktop/output.c +++ b/sway/desktop/output.c | |||
@@ -840,8 +840,9 @@ static void handle_mode(struct wl_listener *listener, void *data) { | |||
840 | arrange_output(output); | 840 | arrange_output(output); |
841 | transaction_commit_dirty(); | 841 | transaction_commit_dirty(); |
842 | 842 | ||
843 | wlr_damage_ring_set_bounds(&output->damage_ring, | 843 | int width, height; |
844 | output->width, output->height); | 844 | wlr_output_transformed_resolution(output->wlr_output, &width, &height); |
845 | wlr_damage_ring_set_bounds(&output->damage_ring, width, height); | ||
845 | wlr_output_schedule_frame(output->wlr_output); | 846 | wlr_output_schedule_frame(output->wlr_output); |
846 | 847 | ||
847 | update_output_manager_config(output->server); | 848 | update_output_manager_config(output->server); |
@@ -872,11 +873,10 @@ static void handle_commit(struct wl_listener *listener, void *data) { | |||
872 | update_output_manager_config(output->server); | 873 | update_output_manager_config(output->server); |
873 | } | 874 | } |
874 | 875 | ||
875 | if (event->committed & (WLR_OUTPUT_STATE_MODE | | 876 | if (event->committed & (WLR_OUTPUT_STATE_MODE | WLR_OUTPUT_STATE_TRANSFORM)) { |
876 | WLR_OUTPUT_STATE_TRANSFORM | | 877 | int width, height; |
877 | WLR_OUTPUT_STATE_SCALE)) { | 878 | wlr_output_transformed_resolution(output->wlr_output, &width, &height); |
878 | wlr_damage_ring_set_bounds(&output->damage_ring, | 879 | wlr_damage_ring_set_bounds(&output->damage_ring, width, height); |
879 | output->width, output->height); | ||
880 | wlr_output_schedule_frame(output->wlr_output); | 880 | wlr_output_schedule_frame(output->wlr_output); |
881 | } | 881 | } |
882 | } | 882 | } |