diff options
author | Kirill Primak <vyivel@eclair.cafe> | 2022-01-29 23:11:54 +0300 |
---|---|---|
committer | Simon Ser <contact@emersion.fr> | 2022-01-31 11:44:03 +0100 |
commit | ee7668c1f2b5ba31420d972161d6d43fc1c84bb4 (patch) | |
tree | db2d114113e60cfa4f5a1c87813c53868e0bf9f1 /sway/tree/arrange.c | |
parent | xwayland: listen to `request_activate` event (diff) | |
download | sway-ee7668c1f2b5ba31420d972161d6d43fc1c84bb4.tar.gz sway-ee7668c1f2b5ba31420d972161d6d43fc1c84bb4.tar.zst sway-ee7668c1f2b5ba31420d972161d6d43fc1c84bb4.zip |
chore: chase wlr_output_layout_get_box() update
https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/3439
Diffstat (limited to 'sway/tree/arrange.c')
-rw-r--r-- | sway/tree/arrange.c | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/sway/tree/arrange.c b/sway/tree/arrange.c index 4aa82c35..9c1a11e5 100644 --- a/sway/tree/arrange.c +++ b/sway/tree/arrange.c | |||
@@ -311,12 +311,13 @@ void arrange_output(struct sway_output *output) { | |||
311 | if (config->reloading) { | 311 | if (config->reloading) { |
312 | return; | 312 | return; |
313 | } | 313 | } |
314 | const struct wlr_box *output_box = wlr_output_layout_get_box( | 314 | struct wlr_box output_box; |
315 | root->output_layout, output->wlr_output); | 315 | wlr_output_layout_get_box(root->output_layout, |
316 | output->lx = output_box->x; | 316 | output->wlr_output, &output_box); |
317 | output->ly = output_box->y; | 317 | output->lx = output_box.x; |
318 | output->width = output_box->width; | 318 | output->ly = output_box.y; |
319 | output->height = output_box->height; | 319 | output->width = output_box.width; |
320 | output->height = output_box.height; | ||
320 | 321 | ||
321 | for (int i = 0; i < output->workspaces->length; ++i) { | 322 | for (int i = 0; i < output->workspaces->length; ++i) { |
322 | struct sway_workspace *workspace = output->workspaces->items[i]; | 323 | struct sway_workspace *workspace = output->workspaces->items[i]; |
@@ -328,12 +329,12 @@ void arrange_root(void) { | |||
328 | if (config->reloading) { | 329 | if (config->reloading) { |
329 | return; | 330 | return; |
330 | } | 331 | } |
331 | const struct wlr_box *layout_box = | 332 | struct wlr_box layout_box; |
332 | wlr_output_layout_get_box(root->output_layout, NULL); | 333 | wlr_output_layout_get_box(root->output_layout, NULL, &layout_box); |
333 | root->x = layout_box->x; | 334 | root->x = layout_box.x; |
334 | root->y = layout_box->y; | 335 | root->y = layout_box.y; |
335 | root->width = layout_box->width; | 336 | root->width = layout_box.width; |
336 | root->height = layout_box->height; | 337 | root->height = layout_box.height; |
337 | 338 | ||
338 | if (root->fullscreen_global) { | 339 | if (root->fullscreen_global) { |
339 | struct sway_container *fs = root->fullscreen_global; | 340 | struct sway_container *fs = root->fullscreen_global; |