diff options
author | Andreas Kling <kling@serenityos.org> | 2020-05-10 14:46:23 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-05-10 14:46:23 +0200 |
commit | c6f098c5a90c7488f29d0092bb9d8ec7c32f2c1f (patch) | |
tree | 59165d8ccc222671698c21bc5bbe427f57690d09 | |
parent | 61e112d3b7edf24abbaef8a3034f716ecfd898cf (diff) | |
download | serenity-c6f098c5a90c7488f29d0092bb9d8ec7c32f2c1f.zip |
WindowServer: Add 2px of tasteful space above maximized windows
This makes the visual interaction between the menu bar and the window
a lot less janky looking.
-rw-r--r-- | Services/WindowServer/WindowManager.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Services/WindowServer/WindowManager.cpp b/Services/WindowServer/WindowManager.cpp index a5fac927d0..52b437169a 100644 --- a/Services/WindowServer/WindowManager.cpp +++ b/Services/WindowServer/WindowManager.cpp @@ -1252,6 +1252,10 @@ Gfx::Rect WindowManager::maximized_window_rect(const Window& window) const return IterationDecision::Break; }); + constexpr int tasteful_space_above_maximized_window = 2; + rect.set_y(rect.y() + tasteful_space_above_maximized_window); + rect.set_height(rect.height() - tasteful_space_above_maximized_window); + return rect; } |