From f4fab5a2b06c37df08d2d315bcb44d15af1786a4 Mon Sep 17 00:00:00 2001 From: salmonik Date: Mon, 17 Aug 2026 19:08:47 +0200 Subject: wm: keep windows in place when the console scrolls beneath them The console's batched scroll (gop::shift_up_n) shifts the whole shared shadow, which dragged any composited window pixels up with it. Add a scroll hook so the window manager re-composites every visible window after a console scroll, restoring them at their fixed positions. --- rsnix/src/vt.rs | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'rsnix/src/vt.rs') diff --git a/rsnix/src/vt.rs b/rsnix/src/vt.rs index c5fc5fd..4ef568d 100644 --- a/rsnix/src/vt.rs +++ b/rsnix/src/vt.rs @@ -458,13 +458,7 @@ fn put_byte(b: u8) { } fn param(i: usize, default: usize) -> usize { - unsafe { - if i < NPARAMS { - PARAMS[i] - } else { - default - } - } + unsafe { if i < NPARAMS { PARAMS[i] } else { default } } } /// Place a printable glyph at the cursor and advance (wrapping/scrolling). @@ -694,6 +688,7 @@ pub fn sync_scroll() { PENDING_SCROLLS = 0; LAST_SYNC_TICK = crate::interrupts::TICKS.load(core::sync::atomic::Ordering::Relaxed); flush(); + gop::call_scroll_hook(); } } -- cgit v1.2.3