1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 18:18:12 +00:00

WindowServer: Introduce a WM event mask so Taskbar can ignore window rects.

Taskbar was waking up to do nothing every time a window rect changed.
This commit is contained in:
Andreas Kling 2019-04-20 14:40:38 +02:00
parent ab94a6be00
commit 49e7ffc06a
10 changed files with 97 additions and 3 deletions

View file

@ -30,9 +30,13 @@ public:
FocusOut,
WindowCloseRequest,
ContextMenu,
__Begin_WM_Events,
WM_WindowRemoved,
WM_WindowStateChanged,
WM_WindowRectChanged,
WM_WindowIconChanged,
__End_WM_Events,
};
GEvent() { }
@ -95,6 +99,20 @@ private:
bool m_minimized;
};
class GWMWindowRectChangedEvent : public GWMEvent {
public:
GWMWindowRectChangedEvent(int client_id, int window_id, const Rect& rect)
: GWMEvent(GEvent::Type::WM_WindowRectChanged, client_id, window_id)
, m_rect(rect)
{
}
Rect rect() const { return m_rect; }
private:
Rect m_rect;
};
class GWMWindowIconChangedEvent : public GWMEvent {
public:
GWMWindowIconChangedEvent(int client_id, int window_id, const String& icon_path)