1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 22:57:44 +00:00

WindowsServer+LibGUI: Avoid getting color under cursor outside screen

This patch fixes a crash in ColorPicker caused by the ColorSelectOverlay
trying to request the color for a pixel outside the screen rect.
This commit is contained in:
networkException 2021-12-31 23:05:35 +01:00 committed by Andreas Kling
parent 8515d7d5ab
commit b46ea5158d
3 changed files with 9 additions and 4 deletions

View file

@ -137,7 +137,7 @@ endpoint WindowServer
get_screen_bitmap(Optional<Gfx::IntRect> rect, Optional<u32> screen_index) => (Gfx::ShareableBitmap bitmap)
get_screen_bitmap_around_cursor(Gfx::IntSize size) => (Gfx::ShareableBitmap bitmap)
get_color_under_cursor() => (Gfx::Color color)
get_color_under_cursor() => (Optional<Gfx::Color> color)
pong() =|