View: move borders state to State struct

This state affects rendering, so it should pass through the transaction
system like the rest.
This commit is contained in:
Isaac Freund
2023-03-01 16:12:27 +01:00
parent c1c72e23a3
commit 50513390ce
5 changed files with 9 additions and 10 deletions

View File

@ -748,7 +748,7 @@ fn processMotion(self: *Self, device: *wlr.InputDevice, time: u32, delta_x: f64,
data.delta_x = dx - @trunc(dx);
data.delta_y = dy - @trunc(dy);
const border_width = if (data.view.draw_borders) server.config.border_width else 0;
const border_width = if (data.view.pending.borders) server.config.border_width else 0;
// Set width/height of view, clamp to view size constraints and output dimensions
data.view.pending.box.width += @floatToInt(i32, dx);