| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "sky/engine/config.h" | 5 #include "sky/engine/config.h" |
| 6 #include "sky/engine/core/animation/DeferredLegacyStyleInterpolation.h" | 6 #include "sky/engine/core/animation/DeferredLegacyStyleInterpolation.h" |
| 7 | 7 |
| 8 #include "sky/engine/core/animation/LegacyStyleInterpolation.h" | 8 #include "sky/engine/core/animation/LegacyStyleInterpolation.h" |
| 9 #include "sky/engine/core/css/CSSImageValue.h" | 9 #include "sky/engine/core/css/CSSImageValue.h" |
| 10 #include "sky/engine/core/css/CSSPrimitiveValue.h" | 10 #include "sky/engine/core/css/CSSPrimitiveValue.h" |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 return false; | 59 return false; |
| 60 | 60 |
| 61 if (primitiveValue.isLength()) | 61 if (primitiveValue.isLength()) |
| 62 return primitiveValue.isFontRelativeLength() || primitiveValue.isViewpor
tPercentageLength(); | 62 return primitiveValue.isFontRelativeLength() || primitiveValue.isViewpor
tPercentageLength(); |
| 63 | 63 |
| 64 if (primitiveValue.isCalculated()) { | 64 if (primitiveValue.isCalculated()) { |
| 65 CSSLengthArray lengthArray(CSSPrimitiveValue::LengthUnitTypeCount); | 65 CSSLengthArray lengthArray(CSSPrimitiveValue::LengthUnitTypeCount); |
| 66 primitiveValue.accumulateLengthArray(lengthArray); | 66 primitiveValue.accumulateLengthArray(lengthArray); |
| 67 return lengthArray[CSSPrimitiveValue::UnitTypeFontSize] != 0 | 67 return lengthArray[CSSPrimitiveValue::UnitTypeFontSize] != 0 |
| 68 || lengthArray[CSSPrimitiveValue::UnitTypeFontXSize] != 0 | 68 || lengthArray[CSSPrimitiveValue::UnitTypeFontXSize] != 0 |
| 69 || lengthArray[CSSPrimitiveValue::UnitTypeRootFontSize] != 0 | |
| 70 || lengthArray[CSSPrimitiveValue::UnitTypeZeroCharacterWidth] != 0 | 69 || lengthArray[CSSPrimitiveValue::UnitTypeZeroCharacterWidth] != 0 |
| 71 || lengthArray[CSSPrimitiveValue::UnitTypeViewportWidth] != 0 | 70 || lengthArray[CSSPrimitiveValue::UnitTypeViewportWidth] != 0 |
| 72 || lengthArray[CSSPrimitiveValue::UnitTypeViewportHeight] != 0 | 71 || lengthArray[CSSPrimitiveValue::UnitTypeViewportHeight] != 0 |
| 73 || lengthArray[CSSPrimitiveValue::UnitTypeViewportMin] != 0 | 72 || lengthArray[CSSPrimitiveValue::UnitTypeViewportMin] != 0 |
| 74 || lengthArray[CSSPrimitiveValue::UnitTypeViewportMax] != 0; | 73 || lengthArray[CSSPrimitiveValue::UnitTypeViewportMax] != 0; |
| 75 } | 74 } |
| 76 | 75 |
| 77 if (Pair* pair = primitiveValue.getPairValue()) { | 76 if (Pair* pair = primitiveValue.getPairValue()) { |
| 78 return interpolationRequiresStyleResolve(*pair->first()) | 77 return interpolationRequiresStyleResolve(*pair->first()) |
| 79 || interpolationRequiresStyleResolve(*pair->second()); | 78 || interpolationRequiresStyleResolve(*pair->second()); |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 return false; | 123 return false; |
| 125 } | 124 } |
| 126 | 125 |
| 127 bool DeferredLegacyStyleInterpolation::interpolationRequiresStyleResolve(const C
SSBasicShape& shape) | 126 bool DeferredLegacyStyleInterpolation::interpolationRequiresStyleResolve(const C
SSBasicShape& shape) |
| 128 { | 127 { |
| 129 // FIXME: Should determine the specific shape, and inspect the members. | 128 // FIXME: Should determine the specific shape, and inspect the members. |
| 130 return false; | 129 return false; |
| 131 } | 130 } |
| 132 | 131 |
| 133 } | 132 } |
| OLD | NEW |