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 1496 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1507 validPrimitive = validUnit(value, FLength | FPercent | FNonNeg); | 1507 validPrimitive = validUnit(value, FLength | FPercent | FNonNeg); |
1508 break; | 1508 break; |
1509 case CSSPropertyShapeImageThreshold: | 1509 case CSSPropertyShapeImageThreshold: |
1510 validPrimitive = validUnit(value, FNumber); | 1510 validPrimitive = validUnit(value, FNumber); |
1511 break; | 1511 break; |
1512 | 1512 |
1513 case CSSPropertyTouchAction: | 1513 case CSSPropertyTouchAction: |
1514 parsedValue = parseTouchAction(); | 1514 parsedValue = parseTouchAction(); |
1515 break; | 1515 break; |
1516 | 1516 |
1517 case CSSPropertyScrollBlocksOn: | |
1518 if (id == CSSValueNone) | |
1519 validPrimitive = true; | |
1520 else | |
1521 parsedValue = parseScrollBlocksOn(); | |
1522 break; | |
1523 | |
1524 case CSSPropertyAlignContent: | 1517 case CSSPropertyAlignContent: |
1525 parsedValue = parseContentDistributionOverflowPosition(); | 1518 parsedValue = parseContentDistributionOverflowPosition(); |
1526 break; | 1519 break; |
1527 | 1520 |
1528 case CSSPropertyAlignSelf: | 1521 case CSSPropertyAlignSelf: |
1529 ASSERT(RuntimeEnabledFeatures::cssGridLayoutEnabled()); | 1522 ASSERT(RuntimeEnabledFeatures::cssGridLayoutEnabled()); |
1530 return parseItemPositionOverflowPosition(propId, important); | 1523 return parseItemPositionOverflowPosition(propId, important); |
1531 | 1524 |
1532 case CSSPropertyAlignItems: | 1525 case CSSPropertyAlignItems: |
1533 ASSERT(RuntimeEnabledFeatures::cssGridLayoutEnabled()); | 1526 ASSERT(RuntimeEnabledFeatures::cssGridLayoutEnabled()); |
(...skipping 5600 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7134 } | 7127 } |
7135 value = m_valueList->next(); | 7128 value = m_valueList->next(); |
7136 } | 7129 } |
7137 | 7130 |
7138 if (list->length()) | 7131 if (list->length()) |
7139 return list.release(); | 7132 return list.release(); |
7140 | 7133 |
7141 return nullptr; | 7134 return nullptr; |
7142 } | 7135 } |
7143 | 7136 |
7144 PassRefPtrWillBeRawPtr<CSSValue> CSSPropertyParser::parseScrollBlocksOn() | |
7145 { | |
7146 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSpaceSeparated()
; | |
7147 CSSParserValue* value = m_valueList->current(); | |
7148 while (value) { | |
7149 switch (value->id) { | |
7150 case CSSValueStartTouch: | |
7151 case CSSValueWheelEvent: | |
7152 case CSSValueScrollEvent: { | |
7153 RefPtrWillBeRawPtr<CSSValue> flagValue = cssValuePool().createIdenti
fierValue(value->id); | |
7154 if (list->hasValue(flagValue.get())) | |
7155 return nullptr; | |
7156 list->append(flagValue.release()); | |
7157 break; | |
7158 } | |
7159 default: | |
7160 return nullptr; | |
7161 } | |
7162 value = m_valueList->next(); | |
7163 } | |
7164 | |
7165 ASSERT(list->length()); | |
7166 return list.release(); | |
7167 } | |
7168 | |
7169 PassRefPtrWillBeRawPtr<CSSValue> CSSPropertyParser::parseTextDecoration() | 7137 PassRefPtrWillBeRawPtr<CSSValue> CSSPropertyParser::parseTextDecoration() |
7170 { | 7138 { |
7171 CSSParserValue* value = m_valueList->current(); | 7139 CSSParserValue* value = m_valueList->current(); |
7172 if (value && value->id == CSSValueNone) { | 7140 if (value && value->id == CSSValueNone) { |
7173 m_valueList->next(); | 7141 m_valueList->next(); |
7174 return cssValuePool().createIdentifierValue(CSSValueNone); | 7142 return cssValuePool().createIdentifierValue(CSSValueNone); |
7175 } | 7143 } |
7176 | 7144 |
7177 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSpaceSeparated()
; | 7145 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSpaceSeparated()
; |
7178 bool isValid = true; | 7146 bool isValid = true; |
(...skipping 964 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8143 } | 8111 } |
8144 } | 8112 } |
8145 | 8113 |
8146 if (!list->length()) | 8114 if (!list->length()) |
8147 return nullptr; | 8115 return nullptr; |
8148 | 8116 |
8149 return list.release(); | 8117 return list.release(); |
8150 } | 8118 } |
8151 | 8119 |
8152 } // namespace blink | 8120 } // namespace blink |
OLD | NEW |