mirror of
https://github.com/RGBCube/serenity
synced 2025-05-20 11:55:08 +00:00
Move LibGUI/GStyle to SharedGraphics/StylePainter.
I want to paint some buttons in WindowServer where we don't have LibGUI.
This commit is contained in:
parent
d12b6b8677
commit
c7ab643883
13 changed files with 47 additions and 46 deletions
|
@ -1,7 +1,7 @@
|
|||
#pragma once
|
||||
|
||||
#include <LibGUI/GWidget.h>
|
||||
#include <LibGUI/GStyle.h>
|
||||
#include <SharedGraphics/StylePainter.h>
|
||||
#include <AK/AKString.h>
|
||||
#include <AK/Function.h>
|
||||
#include <SharedGraphics/GraphicsBitmap.h>
|
||||
|
@ -20,8 +20,8 @@ public:
|
|||
|
||||
Function<void(GButton&)> on_click;
|
||||
|
||||
void set_button_style(GButtonStyle style) { m_button_style = style; }
|
||||
GButtonStyle button_style() const { return m_button_style; }
|
||||
void set_button_style(ButtonStyle style) { m_button_style = style; }
|
||||
ButtonStyle button_style() const { return m_button_style; }
|
||||
|
||||
void click();
|
||||
|
||||
|
@ -37,7 +37,7 @@ private:
|
|||
|
||||
String m_caption;
|
||||
RetainPtr<GraphicsBitmap> m_icon;
|
||||
GButtonStyle m_button_style { GButtonStyle::Normal };
|
||||
ButtonStyle m_button_style { ButtonStyle::Normal };
|
||||
bool m_being_pressed { false };
|
||||
bool m_hovered { false };
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue