mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 08:37:46 +00:00
WindowServer: Fix crash when hovering over title buttons
This fixes a crash where if you switched to a theme that has hover icons for title buttons, then back to a theme that does not. Then when you next hover over the title buttons the window server would crash. This was due to the hover_bitmap multi-scale bitmap pointer being non-null, but not containing any bitmaps, so hitting an assertion when painting.
This commit is contained in:
parent
74695ce76e
commit
857a767ab4
2 changed files with 2 additions and 1 deletions
|
@ -24,6 +24,7 @@ public:
|
|||
Gfx::BitmapFormat format() const { return m_format; }
|
||||
bool load(StringView filename, StringView default_filename = {});
|
||||
void add_bitmap(int scale_factor, NonnullRefPtr<Gfx::Bitmap>&&);
|
||||
bool is_empty() const { return m_bitmaps.is_empty(); }
|
||||
|
||||
private:
|
||||
MultiScaleBitmaps() = default;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue