mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 19:18:12 +00:00
WindowServer: Expose window parent information and more modal improvements
* The parent information is necessary by the Taskbar to be able to determine a modal window's parent * Minimize and maximize modal window stacks together
This commit is contained in:
parent
2f731150a2
commit
bbdf0665fc
8 changed files with 113 additions and 43 deletions
|
@ -114,31 +114,40 @@ public:
|
|||
|
||||
class WMWindowStateChangedEvent : public WMEvent {
|
||||
public:
|
||||
WMWindowStateChangedEvent(int client_id, int window_id, const StringView& title, const Gfx::IntRect& rect, bool is_active, WindowType window_type, bool is_minimized, bool is_frameless, int progress)
|
||||
WMWindowStateChangedEvent(int client_id, int window_id, int parent_client_id, int parent_window_id, const StringView& title, const Gfx::IntRect& rect, bool is_active, bool is_modal, WindowType window_type, bool is_minimized, bool is_frameless, int progress)
|
||||
: WMEvent(Event::Type::WM_WindowStateChanged, client_id, window_id)
|
||||
, m_parent_client_id(parent_client_id)
|
||||
, m_parent_window_id(parent_window_id)
|
||||
, m_title(title)
|
||||
, m_rect(rect)
|
||||
, m_window_type(window_type)
|
||||
, m_active(is_active)
|
||||
, m_modal(is_modal)
|
||||
, m_minimized(is_minimized)
|
||||
, m_frameless(is_frameless)
|
||||
, m_progress(progress)
|
||||
{
|
||||
}
|
||||
|
||||
int parent_client_id() const { return m_parent_client_id; }
|
||||
int parent_window_id() const { return m_parent_window_id; }
|
||||
String title() const { return m_title; }
|
||||
Gfx::IntRect rect() const { return m_rect; }
|
||||
bool is_active() const { return m_active; }
|
||||
bool is_modal() const { return m_modal; }
|
||||
WindowType window_type() const { return m_window_type; }
|
||||
bool is_minimized() const { return m_minimized; }
|
||||
bool is_frameless() const { return m_frameless; }
|
||||
int progress() const { return m_progress; }
|
||||
|
||||
private:
|
||||
int m_parent_client_id;
|
||||
int m_parent_window_id;
|
||||
String m_title;
|
||||
Gfx::IntRect m_rect;
|
||||
WindowType m_window_type;
|
||||
bool m_active;
|
||||
bool m_modal;
|
||||
bool m_minimized;
|
||||
bool m_frameless;
|
||||
int m_progress;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue