diff options
author | Andreas Kling <kling@serenityos.org> | 2020-01-25 10:39:09 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-01-25 10:41:23 +0100 |
commit | b648997d1f89f5affc84f88ea8dc5f5698367250 (patch) | |
tree | b010bd69c111fa31a4e42d44047eed0a22a55272 /Servers/WindowServer/WSWindowFrame.cpp | |
parent | 6df81c8a881b1defea57e4f490f9e09cbd753879 (diff) | |
download | serenity-b648997d1f89f5affc84f88ea8dc5f5698367250.zip |
WindowServer: Don't allow minimize/maximize of windows while modal up
While one window is blocked by another modal one, just ignore events on
the window frame, and also ignore set_minimized() and set_maximized().
The only thing you're allowed to do with a blocked window is moving it.
Fixes #1111.
Diffstat (limited to 'Servers/WindowServer/WSWindowFrame.cpp')
-rw-r--r-- | Servers/WindowServer/WSWindowFrame.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Servers/WindowServer/WSWindowFrame.cpp b/Servers/WindowServer/WSWindowFrame.cpp index 8ec0951006..29da743144 100644 --- a/Servers/WindowServer/WSWindowFrame.cpp +++ b/Servers/WindowServer/WSWindowFrame.cpp @@ -306,6 +306,9 @@ void WSWindowFrame::on_mouse_event(const WSMouseEvent& event) { ASSERT(!m_window.is_fullscreen()); + if (m_window.is_blocked_by_modal_window()) + return; + auto& wm = WSWindowManager::the(); if (m_window.type() != WSWindowType::Normal) return; |