mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 16:07:45 +00:00
WindowServer+NotificationServer: Vertical title bar for notifications
This patch adds a specialized window type for notifications. They now have a title bar on the right-hand side, with a close button. This removes the need for the "Done" button in notifications, giving us a bit more horizontal space overall. Design based on a mock-up from @xTibor :^)
This commit is contained in:
parent
cbd7effd3b
commit
012a4eb0b5
7 changed files with 115 additions and 60 deletions
|
@ -54,6 +54,17 @@ public:
|
|||
void did_set_maximized(Badge<Window>, bool);
|
||||
|
||||
private:
|
||||
void paint_notification_frame(Gfx::Painter&);
|
||||
void paint_normal_frame(Gfx::Painter&);
|
||||
|
||||
struct FrameColors {
|
||||
Color title_color;
|
||||
Color border_color;
|
||||
Color border_color2;
|
||||
};
|
||||
|
||||
FrameColors compute_frame_colors() const;
|
||||
|
||||
Window& m_window;
|
||||
NonnullOwnPtrVector<Button> m_buttons;
|
||||
Button* m_maximize_button { nullptr };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue