window: export hasMouse

hasMouse should have been marked pub
This commit is contained in:
Tim Culverhouse 2024-04-16 13:04:30 -05:00
parent 606272f471
commit 3a928be693

View file

@ -385,7 +385,7 @@ pub fn scroll(self: Window, n: usize) void {
/// returns the mouse event if the mouse event occurred within the window. If /// returns the mouse event if the mouse event occurred within the window. If
/// the mouse event occurred outside the window, null is returned /// the mouse event occurred outside the window, null is returned
fn hasMouse(win: Window, mouse: ?Mouse) ?Mouse { pub fn hasMouse(win: Window, mouse: ?Mouse) ?Mouse {
const event = mouse orelse return null; const event = mouse orelse return null;
if (event.col >= win.x_off and if (event.col >= win.x_off and
event.col < (win.x_off + win.width) and event.col < (win.x_off + win.width) and