diff options
author | Andreas Kling <kling@serenityos.org> | 2022-03-10 15:50:57 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2022-03-11 00:21:49 +0100 |
commit | 053766d79cc0916d073a96c3b4a515ba9d714cf6 (patch) | |
tree | 48f92ceeaeb5bc19dc262f6174749b249f1514f7 /Userland/Libraries/LibWeb/Painting/SVGPaintable.cpp | |
parent | 0500dbc3f6e132cc4cb25b53812e2e71d04ff326 (diff) | |
download | serenity-053766d79cc0916d073a96c3b4a515ba9d714cf6.zip |
LibWeb: Split Paintable into Paintable and PaintableBox
To prepare for paintable inline content, we take the basic painting
functionality and hoist it into a base class.
Diffstat (limited to 'Userland/Libraries/LibWeb/Painting/SVGPaintable.cpp')
-rw-r--r-- | Userland/Libraries/LibWeb/Painting/SVGPaintable.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Userland/Libraries/LibWeb/Painting/SVGPaintable.cpp b/Userland/Libraries/LibWeb/Painting/SVGPaintable.cpp index febe538e58..22f8898f5e 100644 --- a/Userland/Libraries/LibWeb/Painting/SVGPaintable.cpp +++ b/Userland/Libraries/LibWeb/Painting/SVGPaintable.cpp @@ -10,18 +10,18 @@ namespace Web::Painting { SVGPaintable::SVGPaintable(Layout::SVGBox const& layout_box) - : Paintable(layout_box) + : PaintableBox(layout_box) { } Layout::SVGBox const& SVGPaintable::layout_box() const { - return static_cast<Layout::SVGBox const&>(m_layout_box); + return static_cast<Layout::SVGBox const&>(layout_node()); } void SVGPaintable::before_children_paint(PaintContext& context, PaintPhase phase) const { - Paintable::before_children_paint(context, phase); + PaintableBox::before_children_paint(context, phase); if (phase != PaintPhase::Foreground) return; context.svg_context().save(); @@ -29,7 +29,7 @@ void SVGPaintable::before_children_paint(PaintContext& context, PaintPhase phase void SVGPaintable::after_children_paint(PaintContext& context, PaintPhase phase) const { - Paintable::after_children_paint(context, phase); + PaintableBox::after_children_paint(context, phase); if (phase != PaintPhase::Foreground) return; context.svg_context().restore(); |