| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 4 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) | 4 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) |
| 5 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) | 5 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) |
| 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
All rights reserved. | 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
All rights reserved. |
| 7 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> | 7 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> |
| 8 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> | 8 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> |
| 9 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 9 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 10 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. | 10 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | 29 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT |
| 30 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | 30 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
| 31 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | 31 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
| 32 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | 32 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
| 33 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 33 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
| 34 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 34 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 35 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 35 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 36 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 36 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 37 */ | 37 */ |
| 38 | 38 |
| 39 #include "config.h" | 39 #include "sky/engine/config.h" |
| 40 | 40 |
| 41 #include "gen/sky/core/CSSPropertyNames.h" | 41 #include "gen/sky/core/CSSPropertyNames.h" |
| 42 #include "gen/sky/core/CSSValueKeywords.h" | 42 #include "gen/sky/core/CSSValueKeywords.h" |
| 43 #include "gen/sky/core/StyleBuilderFunctions.h" | 43 #include "gen/sky/core/StyleBuilderFunctions.h" |
| 44 #include "gen/sky/core/StylePropertyShorthand.h" | 44 #include "gen/sky/core/StylePropertyShorthand.h" |
| 45 #include "core/css/BasicShapeFunctions.h" | 45 #include "sky/engine/core/css/BasicShapeFunctions.h" |
| 46 #include "core/css/CSSAspectRatioValue.h" | 46 #include "sky/engine/core/css/CSSAspectRatioValue.h" |
| 47 #include "core/css/CSSCursorImageValue.h" | 47 #include "sky/engine/core/css/CSSCursorImageValue.h" |
| 48 #include "core/css/CSSFontValue.h" | 48 #include "sky/engine/core/css/CSSFontValue.h" |
| 49 #include "core/css/CSSGradientValue.h" | 49 #include "sky/engine/core/css/CSSGradientValue.h" |
| 50 #include "core/css/CSSHelper.h" | 50 #include "sky/engine/core/css/CSSHelper.h" |
| 51 #include "core/css/CSSImageSetValue.h" | 51 #include "sky/engine/core/css/CSSImageSetValue.h" |
| 52 #include "core/css/CSSLineBoxContainValue.h" | 52 #include "sky/engine/core/css/CSSLineBoxContainValue.h" |
| 53 #include "core/css/parser/BisonCSSParser.h" | 53 #include "sky/engine/core/css/CSSPrimitiveValueMappings.h" |
| 54 #include "core/css/CSSPrimitiveValueMappings.h" | 54 #include "sky/engine/core/css/CSSPropertyMetadata.h" |
| 55 #include "core/css/CSSPropertyMetadata.h" | 55 #include "sky/engine/core/css/Pair.h" |
| 56 #include "core/css/Pair.h" | 56 #include "sky/engine/core/css/StylePropertySet.h" |
| 57 #include "core/css/StylePropertySet.h" | 57 #include "sky/engine/core/css/StyleRule.h" |
| 58 #include "core/css/StyleRule.h" | 58 #include "sky/engine/core/css/parser/BisonCSSParser.h" |
| 59 #include "core/css/resolver/ElementStyleResources.h" | 59 #include "sky/engine/core/css/resolver/ElementStyleResources.h" |
| 60 #include "core/css/resolver/FilterOperationResolver.h" | 60 #include "sky/engine/core/css/resolver/FilterOperationResolver.h" |
| 61 #include "core/css/resolver/FontBuilder.h" | 61 #include "sky/engine/core/css/resolver/FontBuilder.h" |
| 62 #include "core/css/resolver/StyleBuilder.h" | 62 #include "sky/engine/core/css/resolver/StyleBuilder.h" |
| 63 #include "core/css/resolver/TransformBuilder.h" | 63 #include "sky/engine/core/css/resolver/TransformBuilder.h" |
| 64 #include "core/frame/LocalFrame.h" | 64 #include "sky/engine/core/frame/LocalFrame.h" |
| 65 #include "core/frame/Settings.h" | 65 #include "sky/engine/core/frame/Settings.h" |
| 66 #include "core/rendering/style/QuotesData.h" | 66 #include "sky/engine/core/rendering/style/QuotesData.h" |
| 67 #include "core/rendering/style/RenderStyle.h" | 67 #include "sky/engine/core/rendering/style/RenderStyle.h" |
| 68 #include "core/rendering/style/RenderStyleConstants.h" | 68 #include "sky/engine/core/rendering/style/RenderStyleConstants.h" |
| 69 #include "core/rendering/style/StyleGeneratedImage.h" | 69 #include "sky/engine/core/rendering/style/StyleGeneratedImage.h" |
| 70 #include "platform/fonts/FontDescription.h" | 70 #include "sky/engine/platform/fonts/FontDescription.h" |
| 71 #include "wtf/MathExtras.h" | 71 #include "sky/engine/wtf/MathExtras.h" |
| 72 #include "wtf/StdLibExtras.h" | 72 #include "sky/engine/wtf/StdLibExtras.h" |
| 73 #include "wtf/Vector.h" | 73 #include "sky/engine/wtf/Vector.h" |
| 74 | 74 |
| 75 namespace blink { | 75 namespace blink { |
| 76 | 76 |
| 77 void StyleBuilder::applyProperty(CSSPropertyID id, StyleResolverState& state, CS
SValue* value) | 77 void StyleBuilder::applyProperty(CSSPropertyID id, StyleResolverState& state, CS
SValue* value) |
| 78 { | 78 { |
| 79 ASSERT_WITH_MESSAGE(!isExpandedShorthand(id), "Shorthand property id = %d wa
sn't expanded at parsing time", id); | 79 ASSERT_WITH_MESSAGE(!isExpandedShorthand(id), "Shorthand property id = %d wa
sn't expanded at parsing time", id); |
| 80 | 80 |
| 81 bool isInherit = state.parentNode() && value->isInheritedValue(); | 81 bool isInherit = state.parentNode() && value->isInheritedValue(); |
| 82 bool isInitial = value->isInitialValue() || (!state.parentNode() && value->i
sInheritedValue()); | 82 bool isInitial = value->isInitialValue() || (!state.parentNode() && value->i
sInheritedValue()); |
| 83 | 83 |
| (...skipping 748 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 832 state.style()->setPerspective(perspectiveValue); | 832 state.style()->setPerspective(perspectiveValue); |
| 833 } | 833 } |
| 834 | 834 |
| 835 void StyleBuilderFunctions::applyValueCSSPropertyWebkitTextOrientation(StyleReso
lverState& state, CSSValue* value) | 835 void StyleBuilderFunctions::applyValueCSSPropertyWebkitTextOrientation(StyleReso
lverState& state, CSSValue* value) |
| 836 { | 836 { |
| 837 if (value->isPrimitiveValue()) | 837 if (value->isPrimitiveValue()) |
| 838 state.setTextOrientation(*toCSSPrimitiveValue(value)); | 838 state.setTextOrientation(*toCSSPrimitiveValue(value)); |
| 839 } | 839 } |
| 840 | 840 |
| 841 } // namespace blink | 841 } // namespace blink |
| OLD | NEW |