OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004 Zack Rusin <zack@kde.org> | 2 * Copyright (C) 2004 Zack Rusin <zack@kde.org> |
3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. |
4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> | 4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> |
5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> | 5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> |
6 * Copyright (C) 2011 Sencha, Inc. All rights reserved. | 6 * Copyright (C) 2011 Sencha, Inc. All rights reserved. |
7 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Lesser General Public | 9 * modify it under the terms of the GNU Lesser General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 1445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1456 | 1456 |
1457 static PassRefPtrWillBeRawPtr<CSSValue> touchActionFlagsToCSSValue(TouchAction t
ouchAction) | 1457 static PassRefPtrWillBeRawPtr<CSSValue> touchActionFlagsToCSSValue(TouchAction t
ouchAction) |
1458 { | 1458 { |
1459 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSpaceSeparated()
; | 1459 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSpaceSeparated()
; |
1460 if (touchAction == TouchActionAuto) | 1460 if (touchAction == TouchActionAuto) |
1461 list->append(cssValuePool().createIdentifierValue(CSSValueAuto)); | 1461 list->append(cssValuePool().createIdentifierValue(CSSValueAuto)); |
1462 if (touchAction & TouchActionNone) { | 1462 if (touchAction & TouchActionNone) { |
1463 ASSERT(touchAction == TouchActionNone); | 1463 ASSERT(touchAction == TouchActionNone); |
1464 list->append(cssValuePool().createIdentifierValue(CSSValueNone)); | 1464 list->append(cssValuePool().createIdentifierValue(CSSValueNone)); |
1465 } | 1465 } |
1466 if (touchAction & TouchActionPanX) | 1466 if (touchAction == (TouchActionPanX | TouchActionPanY | TouchActionPinchZoom
)) { |
1467 list->append(cssValuePool().createIdentifierValue(CSSValuePanX)); | 1467 list->append(cssValuePool().createIdentifierValue(CSSValueManipulation))
; |
1468 if (touchAction & TouchActionPanY) | 1468 } else { |
1469 list->append(cssValuePool().createIdentifierValue(CSSValuePanY)); | 1469 if (touchAction & TouchActionPanX) |
1470 | 1470 list->append(cssValuePool().createIdentifierValue(CSSValuePanX)); |
| 1471 if (touchAction & TouchActionPanY) |
| 1472 list->append(cssValuePool().createIdentifierValue(CSSValuePanY)); |
| 1473 } |
1471 ASSERT(list->length()); | 1474 ASSERT(list->length()); |
1472 return list.release(); | 1475 return list.release(); |
1473 } | 1476 } |
1474 | 1477 |
1475 static bool isLayoutDependent(CSSPropertyID propertyID, PassRefPtr<RenderStyle>
style, RenderObject* renderer) | 1478 static bool isLayoutDependent(CSSPropertyID propertyID, PassRefPtr<RenderStyle>
style, RenderObject* renderer) |
1476 { | 1479 { |
1477 // Some properties only depend on layout in certain conditions which | 1480 // Some properties only depend on layout in certain conditions which |
1478 // are specified in the main switch statement below. So we can avoid | 1481 // are specified in the main switch statement below. So we can avoid |
1479 // forcing layout in those conditions. The conditions in this switch | 1482 // forcing layout in those conditions. The conditions in this switch |
1480 // statement must remain in sync with the conditions in the main switch. | 1483 // statement must remain in sync with the conditions in the main switch. |
(...skipping 1555 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3036 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB
ackgroundSize, CSSPropertyBackgroundOrigin, | 3039 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB
ackgroundSize, CSSPropertyBackgroundOrigin, |
3037 CSSPropertyB
ackgroundClip }; | 3040 CSSPropertyB
ackgroundClip }; |
3038 | 3041 |
3039 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSlashSeparated()
; | 3042 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSlashSeparated()
; |
3040 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa
ckground, propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlash
Seperator)))); | 3043 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa
ckground, propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlash
Seperator)))); |
3041 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa
ckground, propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSe
perator)))); | 3044 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa
ckground, propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSe
perator)))); |
3042 return list.release(); | 3045 return list.release(); |
3043 } | 3046 } |
3044 | 3047 |
3045 } // namespace WebCore | 3048 } // namespace WebCore |
OLD | NEW |