From 85001185a78a218466da118a66ca54ee61497e1a Mon Sep 17 00:00:00 2001 From: Aliaksandr Kalenik Date: Sun, 6 Jul 2025 22:12:53 +0200 Subject: [PATCH] LibWeb: Remove unnecessary `apply_own_clip_rect()` in PaintableWithLines Own clip rect is alredy applied in `PaintableBox::before_paint()` for all paintables with lines, so there's no need to do it once again in `PaintableWithLines::paint()`. --- Libraries/LibWeb/Painting/PaintableBox.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/Libraries/LibWeb/Painting/PaintableBox.cpp b/Libraries/LibWeb/Painting/PaintableBox.cpp index 12845cc8f64..81471d6dcd9 100644 --- a/Libraries/LibWeb/Painting/PaintableBox.cpp +++ b/Libraries/LibWeb/Painting/PaintableBox.cpp @@ -906,8 +906,6 @@ void PaintableWithLines::paint(PaintContext& context, PaintPhase phase) const PaintableBox::paint(context, phase); - apply_own_clip_rect(context, phase); - // Text shadows // This is yet another loop, but done here because all shadows should appear under all text. // So, we paint the shadows before painting any text. @@ -929,8 +927,6 @@ void PaintableWithLines::paint(PaintContext& context, PaintPhase phase) const if (is(fragment.paintable())) paint_text_fragment(context, static_cast(fragment.paintable()), fragment, phase); } - - clear_own_clip_rect(context, phase); } Paintable::DispatchEventOfSameName PaintableBox::handle_mousedown(Badge, CSSPixelPoint position, unsigned, unsigned)