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 1003 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1014 return 0; | 1014 return 0; |
1015 } | 1015 } |
1016 return cssValuePool().createIdentifierValue(valueId); | 1016 return cssValuePool().createIdentifierValue(valueId); |
1017 } | 1017 } |
1018 return CSSCubicBezierTimingFunctionValue::create(bezierTimingFunctio n->x1(), bezierTimingFunction->y1(), bezierTimingFunction->x2(), bezierTimingFun ction->y2()); | 1018 return CSSCubicBezierTimingFunctionValue::create(bezierTimingFunctio n->x1(), bezierTimingFunction->y1(), bezierTimingFunction->x2(), bezierTimingFun ction->y2()); |
1019 } | 1019 } |
1020 | 1020 |
1021 case TimingFunction::StepsFunction: | 1021 case TimingFunction::StepsFunction: |
1022 { | 1022 { |
1023 const StepsTimingFunction* stepsTimingFunction = toStepsTimingFuncti on(timingFunction); | 1023 const StepsTimingFunction* stepsTimingFunction = toStepsTimingFuncti on(timingFunction); |
1024 if (stepsTimingFunction->subType() == StepsTimingFunction::Custom) | 1024 if (stepsTimingFunction->subType() == StepsTimingFunction::Custom) { |
1025 return CSSStepsTimingFunctionValue::create(stepsTimingFunction-> numberOfSteps(), stepsTimingFunction->stepAtStart()); | 1025 if (stepsTimingFunction->stepAtPosition() != StepsTimingFunction ::StepAtMiddle) |
dstockwell
2014/02/24 04:58:40
Probably better to invert this condition.
Need a
rjwright
2014/02/24 11:17:46
Redundant and removed altogether.
| |
1026 return CSSStepsTimingFunctionValue::create(stepsTimingFuncti on->numberOfSteps(), stepsTimingFunction->stepAtPosition()); | |
1027 return cssValuePool().createIdentifierValue(CSSValueLinear); | |
dstockwell
2014/02/24 04:58:40
Why Linear rather than Ease?
rjwright
2014/02/24 11:17:46
Oops. Yes, this should be ease (Although it also s
| |
1028 } | |
1026 CSSValueID valueId; | 1029 CSSValueID valueId; |
1027 switch (stepsTimingFunction->subType()) { | 1030 switch (stepsTimingFunction->subType()) { |
1028 case StepsTimingFunction::Start: | 1031 case StepsTimingFunction::Start: |
1029 valueId = CSSValueStepStart; | 1032 valueId = CSSValueStepStart; |
1030 break; | 1033 break; |
1034 case StepsTimingFunction::Middle: | |
1035 valueId = CSSValueLinear; | |
1036 break; | |
1031 case StepsTimingFunction::End: | 1037 case StepsTimingFunction::End: |
1032 valueId = CSSValueStepEnd; | 1038 valueId = CSSValueStepEnd; |
1033 break; | 1039 break; |
1034 default: | 1040 default: |
1035 ASSERT_NOT_REACHED(); | 1041 ASSERT_NOT_REACHED(); |
1036 return 0; | 1042 return 0; |
1037 } | 1043 } |
1038 return cssValuePool().createIdentifierValue(valueId); | 1044 return cssValuePool().createIdentifierValue(valueId); |
1039 } | 1045 } |
1040 | 1046 |
(...skipping 2001 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
3042 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB ackgroundSize, CSSPropertyBackgroundOrigin, | 3048 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB ackgroundSize, CSSPropertyBackgroundOrigin, |
3043 CSSPropertyB ackgroundClip }; | 3049 CSSPropertyB ackgroundClip }; |
3044 | 3050 |
3045 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSlashSeparated() ; | 3051 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSlashSeparated() ; |
3046 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa ckground, propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlash Seperator)))); | 3052 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa ckground, propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlash Seperator)))); |
3047 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa ckground, propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSe perator)))); | 3053 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa ckground, propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSe perator)))); |
3048 return list.release(); | 3054 return list.release(); |
3049 } | 3055 } |
3050 | 3056 |
3051 } // namespace WebCore | 3057 } // namespace WebCore |
OLD | NEW |