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 1036 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1047 for (size_t i = 0; i < trackSizes.size(); ++i) | 1047 for (size_t i = 0; i < trackSizes.size(); ++i) |
1048 list->append(valueForGridTrackSize(trackSizes[i], style, renderView)); | 1048 list->append(valueForGridTrackSize(trackSizes[i], style, renderView)); |
1049 return list.release(); | 1049 return list.release(); |
1050 } | 1050 } |
1051 | 1051 |
1052 static PassRefPtr<CSSValue> valueForGridPosition(const GridPosition& position) | 1052 static PassRefPtr<CSSValue> valueForGridPosition(const GridPosition& position) |
1053 { | 1053 { |
1054 if (position.isAuto()) | 1054 if (position.isAuto()) |
1055 return cssValuePool().createIdentifierValue(CSSValueAuto); | 1055 return cssValuePool().createIdentifierValue(CSSValueAuto); |
1056 | 1056 |
1057 return cssValuePool().createValue(position.integerPosition(), CSSPrimitiveVa
lue::CSS_NUMBER); | 1057 if (position.isInteger()) |
| 1058 return cssValuePool().createValue(position.integerPosition(), CSSPrimiti
veValue::CSS_NUMBER); |
| 1059 |
| 1060 RefPtr<CSSValueList> list = CSSValueList::createSpaceSeparated(); |
| 1061 list->append(cssValuePool().createIdentifierValue(CSSValueSpan)); |
| 1062 list->append(cssValuePool().createValue(position.spanPosition(), CSSPrimitiv
eValue::CSS_NUMBER)); |
| 1063 return list; |
1058 } | 1064 } |
1059 static PassRefPtr<CSSValue> createTransitionPropertyValue(const Animation* anima
tion) | 1065 static PassRefPtr<CSSValue> createTransitionPropertyValue(const Animation* anima
tion) |
1060 { | 1066 { |
1061 RefPtr<CSSValue> propertyValue; | 1067 RefPtr<CSSValue> propertyValue; |
1062 if (animation->animationMode() == Animation::AnimateNone) | 1068 if (animation->animationMode() == Animation::AnimateNone) |
1063 propertyValue = cssValuePool().createIdentifierValue(CSSValueNone); | 1069 propertyValue = cssValuePool().createIdentifierValue(CSSValueNone); |
1064 else if (animation->animationMode() == Animation::AnimateAll) | 1070 else if (animation->animationMode() == Animation::AnimateAll) |
1065 propertyValue = cssValuePool().createIdentifierValue(CSSValueAll); | 1071 propertyValue = cssValuePool().createIdentifierValue(CSSValueAll); |
1066 else | 1072 else |
1067 propertyValue = cssValuePool().createValue(getPropertyNameString(animati
on->property()), CSSPrimitiveValue::CSS_STRING); | 1073 propertyValue = cssValuePool().createValue(getPropertyNameString(animati
on->property()), CSSPrimitiveValue::CSS_STRING); |
(...skipping 1944 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3012 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB
ackgroundSize, CSSPropertyBackgroundOrigin, | 3018 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB
ackgroundSize, CSSPropertyBackgroundOrigin, |
3013 CSSPropertyB
ackgroundClip }; | 3019 CSSPropertyB
ackgroundClip }; |
3014 | 3020 |
3015 RefPtr<CSSValueList> list = CSSValueList::createSlashSeparated(); | 3021 RefPtr<CSSValueList> list = CSSValueList::createSlashSeparated(); |
3016 list->append(getCSSPropertyValuesForShorthandProperties(StylePropertyShortha
nd(propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlashSeperat
or)))); | 3022 list->append(getCSSPropertyValuesForShorthandProperties(StylePropertyShortha
nd(propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlashSeperat
or)))); |
3017 list->append(getCSSPropertyValuesForShorthandProperties(StylePropertyShortha
nd(propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSeperator
)))); | 3023 list->append(getCSSPropertyValuesForShorthandProperties(StylePropertyShortha
nd(propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSeperator
)))); |
3018 return list.release(); | 3024 return list.release(); |
3019 } | 3025 } |
3020 | 3026 |
3021 } // namespace WebCore | 3027 } // namespace WebCore |
OLD | NEW |