diff options
-rw-r--r-- | Libraries/LibGUI/Frame.cpp | 6 | ||||
-rw-r--r-- | Libraries/LibGUI/Frame.h | 2 |
2 files changed, 8 insertions, 0 deletions
diff --git a/Libraries/LibGUI/Frame.cpp b/Libraries/LibGUI/Frame.cpp index 9b82c5b7f9..7215f1d985 100644 --- a/Libraries/LibGUI/Frame.cpp +++ b/Libraries/LibGUI/Frame.cpp @@ -59,4 +59,10 @@ void Frame::paint_event(PaintEvent& event) painter.add_clip_rect(event.rect()); Gfx::StylePainter::paint_frame(painter, rect(), palette(), m_shape, m_shadow, m_thickness, spans_entire_window_horizontally()); } + +Gfx::IntRect Frame::children_clip_rect() const +{ + return frame_inner_rect(); +} + } diff --git a/Libraries/LibGUI/Frame.h b/Libraries/LibGUI/Frame.h index 5bf43f238a..6d94112423 100644 --- a/Libraries/LibGUI/Frame.h +++ b/Libraries/LibGUI/Frame.h @@ -48,6 +48,8 @@ public: Gfx::IntRect frame_inner_rect_for_size(const Gfx::IntSize& size) const { return { m_thickness, m_thickness, size.width() - m_thickness * 2, size.height() - m_thickness * 2 }; } Gfx::IntRect frame_inner_rect() const { return frame_inner_rect_for_size(size()); } + virtual Gfx::IntRect children_clip_rect() const override; + protected: Frame(); void paint_event(PaintEvent&) override; |