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/commands | |
parent | 69b430201cb19c666f102586b18f1dfbda7c44a3 (diff) |
chore: chase wlr_output_layout_get_box() update
https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/3439
Diffstat (limited to 'sway/commands')
-rw-r--r-- | sway/commands/move.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/sway/commands/move.c b/sway/commands/move.c index 1a05a7a6..0d0d9727 100644 --- a/sway/commands/move.c +++ b/sway/commands/move.c @@ -788,15 +788,15 @@ static struct cmd_results *cmd_move_to_position_pointer( struct wlr_output *output = wlr_output_layout_output_at( root->output_layout, cursor->x, cursor->y); if (output) { - struct wlr_box *box = - wlr_output_layout_get_box(root->output_layout, output); - lx = fmax(lx, box->x); - ly = fmax(ly, box->y); - if (lx + container->pending.width > box->x + box->width) { - lx = box->x + box->width - container->pending.width; + struct wlr_box box; + wlr_output_layout_get_box(root->output_layout, output, &box); + lx = fmax(lx, box.x); + ly = fmax(ly, box.y); + if (lx + container->pending.width > box.x + box.width) { + lx = box.x + box.width - container->pending.width; } - if (ly + container->pending.height > box->y + box->height) { - ly = box->y + box->height - container->pending.height; + if (ly + container->pending.height > box.y + box.height) { + ly = box.y + box.height - container->pending.height; } } |