From 583fbf711151f2c6856b521163c2ce4cffb5bc47 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Sun, 14 Nov 2021 11:31:33 +0100 Subject: [PATCH] WindowServer: Make WindowFrame::shadow_bitmap() const There is no reason for callers to mutate the shadow bitmaps returned by this function. --- Userland/Services/WindowServer/WindowFrame.cpp | 2 +- Userland/Services/WindowServer/WindowFrame.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Userland/Services/WindowServer/WindowFrame.cpp b/Userland/Services/WindowServer/WindowFrame.cpp index 6bb3c35394..b9d40796e7 100644 --- a/Userland/Services/WindowServer/WindowFrame.cpp +++ b/Userland/Services/WindowServer/WindowFrame.cpp @@ -163,7 +163,7 @@ void WindowFrame::reload_config() load_shadow(WindowManager::the().palette().tooltip_shadow_path(), s_last_tooltip_shadow_path, s_tooltip_shadow); } -MultiScaleBitmaps* WindowFrame::shadow_bitmap() const +MultiScaleBitmaps const* WindowFrame::shadow_bitmap() const { if (m_window.is_frameless() && !m_window.has_forced_shadow()) return nullptr; diff --git a/Userland/Services/WindowServer/WindowFrame.h b/Userland/Services/WindowServer/WindowFrame.h index c91df5dbdc..9e37b8b34f 100644 --- a/Userland/Services/WindowServer/WindowFrame.h +++ b/Userland/Services/WindowServer/WindowFrame.h @@ -124,7 +124,7 @@ private: void paint_normal_frame(Gfx::Painter&); void paint_tool_window_frame(Gfx::Painter&); void paint_menubar(Gfx::Painter&); - MultiScaleBitmaps* shadow_bitmap() const; + MultiScaleBitmaps const* shadow_bitmap() const; Gfx::IntRect inflated_for_shadow(const Gfx::IntRect&) const; void handle_menubar_mouse_event(const MouseEvent&);