diff options
author | Ben Wiederhake <BenWiederhake.GitHub@gmx.de> | 2023-05-06 20:54:38 +0200 |
---|---|---|
committer | Jelle Raaijmakers <jelle@gmta.nl> | 2023-05-06 22:04:46 +0200 |
commit | 4b7639c3b51b142bf6f2bff52097064387c3ed1a (patch) | |
tree | 4e9af31bfba5ea8d69c563e0a537074017dc2c92 /Userland/Services/WindowServer | |
parent | 4c2ad700663fdab7b3778a02734b44495928f603 (diff) | |
download | serenity-4b7639c3b51b142bf6f2bff52097064387c3ed1a.zip |
LibGfx+WindowServer: Ensure constrain-to-rect ends up inside the rect
Diffstat (limited to 'Userland/Services/WindowServer')
-rw-r--r-- | Userland/Services/WindowServer/Screen.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Services/WindowServer/Screen.cpp b/Userland/Services/WindowServer/Screen.cpp index 4b95c9fa3d..2ce1ea4337 100644 --- a/Userland/Services/WindowServer/Screen.cpp +++ b/Userland/Services/WindowServer/Screen.cpp @@ -421,7 +421,7 @@ void ScreenInput::on_receive_mouse_data(MousePacket const& packet) auto* moved_to_screen = Screen::find_by_location(m_cursor_location); if (!moved_to_screen) { - m_cursor_location = m_cursor_location.constrained(current_screen.rect()); + m_cursor_location.constrain(current_screen.rect()); moved_to_screen = ¤t_screen; } |