diff options
author | Linus Groh <mail@linusgroh.de> | 2021-04-15 22:40:58 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-04-16 17:28:05 +0200 |
commit | e632186c17e109f483eeecb44d574b6fb5ce4ba3 (patch) | |
tree | c0fb10ad244520eb3e21b5f314d796fb1cca6fcf /Userland/Services/WindowServer/Window.cpp | |
parent | 0aebb9ec62180dff011ce6c7ab02d3ab74a607ab (diff) | |
download | serenity-e632186c17e109f483eeecb44d574b6fb5ce4ba3.zip |
WindowServer: Recalculate window rect when toggling menubar
This is important when the window is maximized or tiled (which
recalculate_rect() will both check), as we otherwise create a gap above
the window frame (when hiding the menubar) or push the frame off the
screen (when showing the menubar).
Diffstat (limited to 'Userland/Services/WindowServer/Window.cpp')
-rw-r--r-- | Userland/Services/WindowServer/Window.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Userland/Services/WindowServer/Window.cpp b/Userland/Services/WindowServer/Window.cpp index d8f08772e4..7ac529e4cb 100644 --- a/Userland/Services/WindowServer/Window.cpp +++ b/Userland/Services/WindowServer/Window.cpp @@ -700,6 +700,7 @@ void Window::ensure_window_menu() item.set_checked(!item.is_checked()); m_should_show_menubar = item.is_checked(); frame().invalidate(); + recalculate_rect(); Compositor::the().invalidate_occlusions(); Compositor::the().invalidate_screen(); break; |