lua position, size, focus and z-index (not really)

This commit is contained in:
Harrison DiAmbrosio 2025-11-25 16:01:38 -05:00 committed by Squibid
parent 2c130539f6
commit 47bcce621d
Signed by: squibid
GPG key ID: BECE5684D3C4005D
14 changed files with 236 additions and 98 deletions

View file

@ -75,7 +75,7 @@ pub fn processCursorMotion(self: *Cursor, time_msec: u32) void {
switch (self.mode) {
.passthrough => {
if (server.root.viewAt(self.wlr_cursor.x, self.wlr_cursor.y)) |res| {
server.seat.focusView(res.view);
res.view.setFocused();
server.seat.wlr_seat.pointerNotifyEnter(res.surface, res.sx, res.sy);
server.seat.wlr_seat.pointerNotifyMotion(time_msec, res.sx, res.sy);
@ -134,8 +134,7 @@ fn handleButton(
_ = server.seat.wlr_seat.pointerNotifyButton(event.time_msec, event.button, event.state);
if (server.seat.focused_view) |view| {
server.seat.focusView(view);
server.root.focusView(view);
view.setFocused();
}
switch (event.state) {