OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2003 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2003 Lars Knoll (knoll@kde.org) |
3 * Copyright (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 3 * Copyright (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. | 4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. |
5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> | 5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> |
6 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> | 6 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> |
7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) | 7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) |
8 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. | 8 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. |
9 * Copyright (C) 2012 Intel Corporation. All rights reserved. | 9 * Copyright (C) 2012 Intel Corporation. All rights reserved. |
10 * | 10 * |
(...skipping 2827 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2838 } | 2838 } |
2839 } else if (!parsedValue2 && propId == CSSPropertyWebkitBackgroundSize) { | 2839 } else if (!parsedValue2 && propId == CSSPropertyWebkitBackgroundSize) { |
2840 // For backwards compatibility we set the second value to the first if i t is omitted. | 2840 // For backwards compatibility we set the second value to the first if i t is omitted. |
2841 // We only need to do this for -webkit-background-size. It should be saf e to let masks match | 2841 // We only need to do this for -webkit-background-size. It should be saf e to let masks match |
2842 // the real property. | 2842 // the real property. |
2843 parsedValue2 = parsedValue1; | 2843 parsedValue2 = parsedValue1; |
2844 } | 2844 } |
2845 | 2845 |
2846 if (!parsedValue2) | 2846 if (!parsedValue2) |
2847 return parsedValue1; | 2847 return parsedValue1; |
2848 return createPrimitiveValuePair(parsedValue1.release(), parsedValue2.release ()); | 2848 |
2849 // For backwards compatibility. | |
ojan
2014/04/24 01:12:38
This comment seems somewhat lacking in context. Ei
andersr
2014/04/24 11:05:42
OK, I removed it.
| |
2850 Pair::IdenticalValuesPolicy policy = propId == CSSPropertyWebkitBackgroundSi ze ? | |
2851 Pair::DropIdenticalValues : Pair::KeepIdenticalValues; | |
2852 | |
2853 return createPrimitiveValuePair(parsedValue1.release(), parsedValue2.release (), policy); | |
2849 } | 2854 } |
2850 | 2855 |
2851 bool CSSPropertyParser::parseFillProperty(CSSPropertyID propId, CSSPropertyID& p ropId1, CSSPropertyID& propId2, | 2856 bool CSSPropertyParser::parseFillProperty(CSSPropertyID propId, CSSPropertyID& p ropId1, CSSPropertyID& propId2, |
2852 RefPtrWillBeRawPtr<CSSValue>& retValue1, RefPtrWillBeRawPtr<CSSValue>& retVa lue2) | 2857 RefPtrWillBeRawPtr<CSSValue>& retValue1, RefPtrWillBeRawPtr<CSSValue>& retVa lue2) |
2853 { | 2858 { |
2854 RefPtrWillBeRawPtr<CSSValueList> values = nullptr; | 2859 RefPtrWillBeRawPtr<CSSValueList> values = nullptr; |
2855 RefPtrWillBeRawPtr<CSSValueList> values2 = nullptr; | 2860 RefPtrWillBeRawPtr<CSSValueList> values2 = nullptr; |
2856 CSSParserValue* val; | 2861 CSSParserValue* val; |
2857 RefPtrWillBeRawPtr<CSSValue> value = nullptr; | 2862 RefPtrWillBeRawPtr<CSSValue> value = nullptr; |
2858 RefPtrWillBeRawPtr<CSSValue> value2 = nullptr; | 2863 RefPtrWillBeRawPtr<CSSValue> value2 = nullptr; |
(...skipping 5616 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
8475 parsedValues->append(CSSPrimitiveValue::createIdentifier(CSSValueFill)); | 8480 parsedValues->append(CSSPrimitiveValue::createIdentifier(CSSValueFill)); |
8476 if (!seenStroke) | 8481 if (!seenStroke) |
8477 parsedValues->append(CSSPrimitiveValue::createIdentifier(CSSValueStroke) ); | 8482 parsedValues->append(CSSPrimitiveValue::createIdentifier(CSSValueStroke) ); |
8478 if (!seenMarkers) | 8483 if (!seenMarkers) |
8479 parsedValues->append(CSSPrimitiveValue::createIdentifier(CSSValueMarkers )); | 8484 parsedValues->append(CSSPrimitiveValue::createIdentifier(CSSValueMarkers )); |
8480 | 8485 |
8481 return parsedValues.release(); | 8486 return parsedValues.release(); |
8482 } | 8487 } |
8483 | 8488 |
8484 } // namespace WebCore | 8489 } // namespace WebCore |
OLD | NEW |