summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb
diff options
context:
space:
mode:
authorEgor Ananyin <ananinegor@gmail.com>2021-07-23 13:16:04 +0300
committerAli Mohammad Pur <Ali.mpfard@gmail.com>2021-07-24 22:02:28 +0430
commit495f69b76ba6632f805ba2177a2c31c5422e20f1 (patch)
tree422e8f5f3002468d132e4722d6d85ef7584afd1e /Userland/Libraries/LibWeb
parentfaef523567b228dc9ebf683555eb4cbee19c7bb6 (diff)
downloadserenity-495f69b76ba6632f805ba2177a2c31c5422e20f1.zip
LibWeb: Don't paint children stacking contexts inside the current one
Diffstat (limited to 'Userland/Libraries/LibWeb')
-rw-r--r--Userland/Libraries/LibWeb/Painting/StackingContext.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/Userland/Libraries/LibWeb/Painting/StackingContext.cpp b/Userland/Libraries/LibWeb/Painting/StackingContext.cpp
index 57c0dfdaca..7ff683e8b6 100644
--- a/Userland/Libraries/LibWeb/Painting/StackingContext.cpp
+++ b/Userland/Libraries/LibWeb/Painting/StackingContext.cpp
@@ -32,6 +32,8 @@ StackingContext::StackingContext(Box& box, StackingContext* parent)
void StackingContext::paint_descendants(PaintContext& context, Node& box, StackingContextPaintPhase phase)
{
box.for_each_child([&](auto& child) {
+ if (child.establishes_stacking_context())
+ return;
switch (phase) {
case StackingContextPaintPhase::BackgroundAndBorders:
if (!child.is_floating() && !child.is_positioned()) {