mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-26 22:38:51 +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
Notes:
sideshowbarker
2024-07-19 14:54:54 +09:00
Author: https://github.com/awesomekling
Commit: c7ab643883
13 changed files with 47 additions and 46 deletions
|
@ -1,6 +1,6 @@
|
|||
#include "GButton.h"
|
||||
#include <LibGUI/GPainter.h>
|
||||
#include <LibGUI/GStyle.h>
|
||||
#include <SharedGraphics/StylePainter.h>
|
||||
|
||||
//#define GBUTTON_DEBUG
|
||||
|
||||
|
@ -26,7 +26,7 @@ void GButton::paint_event(GPaintEvent& event)
|
|||
GPainter painter(*this);
|
||||
painter.set_clip_rect(event.rect());
|
||||
|
||||
GStyle::the().paint_button(painter, rect(), m_button_style, m_being_pressed, m_hovered);
|
||||
StylePainter::the().paint_button(painter, rect(), m_button_style, m_being_pressed, m_hovered);
|
||||
|
||||
if (!caption().is_empty() || m_icon) {
|
||||
auto content_rect = rect();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue