| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) | 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) |
| 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) | 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) |
| 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
All rights reserved. | 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
All rights reserved. |
| 6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> | 6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> |
| 7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> | 7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> |
| 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. | 9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. |
| 10 * Copyright (C) Research In Motion Limited 2011. All rights reserved. | 10 * Copyright (C) Research In Motion Limited 2011. All rights reserved. |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 case CSSPropertyWebkitTransformStyle: | 85 case CSSPropertyWebkitTransformStyle: |
| 86 case CSSPropertyPerspective: | 86 case CSSPropertyPerspective: |
| 87 case CSSPropertyWebkitPerspective: | 87 case CSSPropertyWebkitPerspective: |
| 88 case CSSPropertyWebkitMask: | 88 case CSSPropertyWebkitMask: |
| 89 case CSSPropertyWebkitMaskBoxImage: | 89 case CSSPropertyWebkitMaskBoxImage: |
| 90 case CSSPropertyWebkitClipPath: | 90 case CSSPropertyWebkitClipPath: |
| 91 case CSSPropertyWebkitFilter: | 91 case CSSPropertyWebkitFilter: |
| 92 case CSSPropertyZIndex: | 92 case CSSPropertyZIndex: |
| 93 case CSSPropertyPosition: | 93 case CSSPropertyPosition: |
| 94 return true; | 94 return true; |
| 95 case CSSPropertyMixBlendMode: | |
| 96 case CSSPropertyIsolation: | |
| 97 if (RuntimeEnabledFeatures::cssCompositingEnabled()) | |
| 98 return true; | |
| 99 break; | |
| 100 default: | 95 default: |
| 101 break; | 96 break; |
| 102 } | 97 } |
| 103 } | 98 } |
| 104 return false; | 99 return false; |
| 105 } | 100 } |
| 106 | 101 |
| 107 void StyleAdjuster::adjustRenderStyle(RenderStyle* style, RenderStyle* parentSty
le, Element& element) | 102 void StyleAdjuster::adjustRenderStyle(RenderStyle* style, RenderStyle* parentSty
le, Element& element) |
| 108 { | 103 { |
| 109 ASSERT(parentStyle); | 104 ASSERT(parentStyle); |
| (...skipping 12 matching lines...) Expand all Loading... |
| 122 | 117 |
| 123 // Auto z-index becomes 0 for the root element and transparent objects. This
prevents | 118 // Auto z-index becomes 0 for the root element and transparent objects. This
prevents |
| 124 // cases where objects that should be blended as a single unit end up with a
non-transparent | 119 // cases where objects that should be blended as a single unit end up with a
non-transparent |
| 125 // object wedged in between them. Auto z-index also becomes 0 for objects th
at specify transforms/masks/reflections. | 120 // object wedged in between them. Auto z-index also becomes 0 for objects th
at specify transforms/masks/reflections. |
| 126 if (style->hasAutoZIndex() && ((element.document().documentElement() == elem
ent) | 121 if (style->hasAutoZIndex() && ((element.document().documentElement() == elem
ent) |
| 127 || style->hasOpacity() | 122 || style->hasOpacity() |
| 128 || style->hasTransformRelatedProperty() | 123 || style->hasTransformRelatedProperty() |
| 129 || style->hasMask() | 124 || style->hasMask() |
| 130 || style->clipPath() | 125 || style->clipPath() |
| 131 || style->hasFilter() | 126 || style->hasFilter() |
| 132 || style->hasBlendMode() | |
| 133 || style->hasIsolation() | |
| 134 || hasWillChangeThatCreatesStackingContext(style))) | 127 || hasWillChangeThatCreatesStackingContext(style))) |
| 135 style->setZIndex(0); | 128 style->setZIndex(0); |
| 136 | 129 |
| 137 // will-change:transform should result in the same rendering behavior as hav
ing a transform, | 130 // will-change:transform should result in the same rendering behavior as hav
ing a transform, |
| 138 // including the creation of a containing block for fixed position descendan
ts. | 131 // including the creation of a containing block for fixed position descendan
ts. |
| 139 if (!style->hasTransform() && (style->willChangeProperties().contains(CSSPro
pertyWebkitTransform) || style->willChangeProperties().contains(CSSPropertyTrans
form))) { | 132 if (!style->hasTransform() && (style->willChangeProperties().contains(CSSPro
pertyWebkitTransform) || style->willChangeProperties().contains(CSSPropertyTrans
form))) { |
| 140 bool makeIdentity = true; | 133 bool makeIdentity = true; |
| 141 style->setTransform(TransformOperations(makeIdentity)); | 134 style->setTransform(TransformOperations(makeIdentity)); |
| 142 } | 135 } |
| 143 | 136 |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 234 } | 227 } |
| 235 | 228 |
| 236 void StyleAdjuster::adjustStyleForDisplay(RenderStyle* style, RenderStyle* paren
tStyle) | 229 void StyleAdjuster::adjustStyleForDisplay(RenderStyle* style, RenderStyle* paren
tStyle) |
| 237 { | 230 { |
| 238 if (parentStyle->isDisplayFlexibleBox()) { | 231 if (parentStyle->isDisplayFlexibleBox()) { |
| 239 style->setDisplay(equivalentBlockDisplay(style->display())); | 232 style->setDisplay(equivalentBlockDisplay(style->display())); |
| 240 } | 233 } |
| 241 } | 234 } |
| 242 | 235 |
| 243 } | 236 } |
| OLD | NEW |