summaryrefslogtreecommitdiff
path: root/LibGUI/GWidget.cpp
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-03-28 17:19:56 +0100
committerAndreas Kling <awesomekling@gmail.com>2019-03-28 17:19:56 +0100
commit9fa21fa5852fc9b7605d953a3e9f8a9e8bd28864 (patch)
tree551051e45da768531505855a2df3e3eccd9f3331 /LibGUI/GWidget.cpp
parent326c6fd607893af0dd6200815540708bc218145d (diff)
downloadserenity-9fa21fa5852fc9b7605d953a3e9f8a9e8bd28864.zip
LibGUI: Add a GPainter class that inherits from Painter.
This gets rid of the last little piece of LibGUI knowledge in Painter.
Diffstat (limited to 'LibGUI/GWidget.cpp')
-rw-r--r--LibGUI/GWidget.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/LibGUI/GWidget.cpp b/LibGUI/GWidget.cpp
index f78ec48ebf..e22dd03b59 100644
--- a/LibGUI/GWidget.cpp
+++ b/LibGUI/GWidget.cpp
@@ -5,7 +5,7 @@
#include <LibGUI/GLayout.h>
#include <AK/Assertions.h>
#include <SharedGraphics/GraphicsBitmap.h>
-#include <SharedGraphics/Painter.h>
+#include <LibGUI/GPainter.h>
#include <unistd.h>
@@ -85,13 +85,13 @@ void GWidget::handle_paint_event(GPaintEvent& event)
{
ASSERT(is_visible());
if (fill_with_background_color()) {
- Painter painter(*this);
+ GPainter painter(*this);
painter.fill_rect(event.rect(), background_color());
} else {
#ifdef DEBUG_WIDGET_UNDERDRAW
// FIXME: This is a bit broken.
// If the widget is not opaque, let's not mess it up with debugging color.
- Painter painter(*this);
+ GPainter painter(*this);
painter.fill_rect(rect(), Color::Red);
#endif
}