OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) |
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. | 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. |
7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. |
8 * | 8 * |
9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
102 { | 102 { |
103 setIsBox(); | 103 setIsBox(); |
104 } | 104 } |
105 | 105 |
106 PaintLayerType LayoutBox::layerTypeRequired() const | 106 PaintLayerType LayoutBox::layerTypeRequired() const |
107 { | 107 { |
108 // hasAutoZIndex only returns true if the element is positioned or a flex-it
em since | 108 // hasAutoZIndex only returns true if the element is positioned or a flex-it
em since |
109 // position:static elements that are not flex-items get their z-index coerce
d to auto. | 109 // position:static elements that are not flex-items get their z-index coerce
d to auto. |
110 if (isPositioned() || createsGroup() || hasClipPath() || hasTransformRelated
Property() | 110 if (isPositioned() || createsGroup() || hasClipPath() || hasTransformRelated
Property() |
111 || style()->hasCompositorProxy() || hasHiddenBackface() || hasReflection
() || style()->specifiesColumns() | 111 || style()->hasCompositorProxy() || hasHiddenBackface() || hasReflection
() || style()->specifiesColumns() |
112 || !style()->hasAutoZIndex() || style()->shouldCompositeForCurrentAnimat
ions()) | 112 || style()->isStackingContext() || style()->shouldCompositeForCurrentAni
mations()) |
113 return NormalPaintLayer; | 113 return NormalPaintLayer; |
114 | 114 |
115 if (hasOverflowClip()) | 115 if (hasOverflowClip()) |
116 return OverflowClipPaintLayer; | 116 return OverflowClipPaintLayer; |
117 | 117 |
118 return NoPaintLayer; | 118 return NoPaintLayer; |
119 } | 119 } |
120 | 120 |
121 void LayoutBox::willBeDestroyed() | 121 void LayoutBox::willBeDestroyed() |
122 { | 122 { |
(...skipping 1259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1382 return false; | 1382 return false; |
1383 if (childStyle.visibility() != VISIBLE || childStyle.shapeOutside()) | 1383 if (childStyle.visibility() != VISIBLE || childStyle.shapeOutside()) |
1384 return false; | 1384 return false; |
1385 if (childBox.size().isZero()) | 1385 if (childBox.size().isZero()) |
1386 return false; | 1386 return false; |
1387 if (PaintLayer* childLayer = childBox.layer()) { | 1387 if (PaintLayer* childLayer = childBox.layer()) { |
1388 // FIXME: perhaps this could be less conservative? | 1388 // FIXME: perhaps this could be less conservative? |
1389 if (childLayer->compositingState() != NotComposited) | 1389 if (childLayer->compositingState() != NotComposited) |
1390 return false; | 1390 return false; |
1391 // FIXME: Deal with z-index. | 1391 // FIXME: Deal with z-index. |
1392 if (!childStyle.hasAutoZIndex()) | 1392 if (childStyle.isStackingContext()) |
1393 return false; | 1393 return false; |
1394 if (childLayer->hasTransformRelatedProperty() || childLayer->isTranspare
nt() || childLayer->hasFilterInducingProperty()) | 1394 if (childLayer->hasTransformRelatedProperty() || childLayer->isTranspare
nt() || childLayer->hasFilterInducingProperty()) |
1395 return false; | 1395 return false; |
1396 if (childBox.hasOverflowClip() && childStyle.hasBorderRadius()) | 1396 if (childBox.hasOverflowClip() && childStyle.hasBorderRadius()) |
1397 return false; | 1397 return false; |
1398 } | 1398 } |
1399 return true; | 1399 return true; |
1400 } | 1400 } |
1401 | 1401 |
1402 bool LayoutBox::foregroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect, u
nsigned maxDepthToTest) const | 1402 bool LayoutBox::foregroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect, u
nsigned maxDepthToTest) const |
(...skipping 3532 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4935 m_rareData->m_snapAreas->remove(&snapArea); | 4935 m_rareData->m_snapAreas->remove(&snapArea); |
4936 } | 4936 } |
4937 } | 4937 } |
4938 | 4938 |
4939 SnapAreaSet* LayoutBox::snapAreas() const | 4939 SnapAreaSet* LayoutBox::snapAreas() const |
4940 { | 4940 { |
4941 return m_rareData ? m_rareData->m_snapAreas.get() : nullptr; | 4941 return m_rareData ? m_rareData->m_snapAreas.get() : nullptr; |
4942 } | 4942 } |
4943 | 4943 |
4944 } // namespace blink | 4944 } // namespace blink |
OLD | NEW |