| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 138 { | 138 { |
| 139 RefPtr<SVGLength> length = toAnimatableSVGLength(value)->toSVGLength(); | 139 RefPtr<SVGLength> length = toAnimatableSVGLength(value)->toSVGLength(); |
| 140 if (length->valueInSpecifiedUnits() < 0) | 140 if (length->valueInSpecifiedUnits() < 0) |
| 141 length->setValueInSpecifiedUnits(0); | 141 length->setValueInSpecifiedUnits(0); |
| 142 return length.release(); | 142 return length.release(); |
| 143 } | 143 } |
| 144 | 144 |
| 145 template <CSSPropertyID property> | 145 template <CSSPropertyID property> |
| 146 void setOnFillLayers(FillLayer* fillLayer, const AnimatableValue* value, StyleRe
solverState& state) | 146 void setOnFillLayers(FillLayer* fillLayer, const AnimatableValue* value, StyleRe
solverState& state) |
| 147 { | 147 { |
| 148 const Vector<RefPtr<AnimatableValue> >& values = toAnimatableRepeatable(valu
e)->values(); | 148 const WillBeHeapVector<RefPtrWillBeMember<AnimatableValue> >& values = toAni
matableRepeatable(value)->values(); |
| 149 ASSERT(!values.isEmpty()); | 149 ASSERT(!values.isEmpty()); |
| 150 FillLayer* prev = 0; | 150 FillLayer* prev = 0; |
| 151 for (size_t i = 0; i < values.size(); ++i) { | 151 for (size_t i = 0; i < values.size(); ++i) { |
| 152 if (!fillLayer) { | 152 if (!fillLayer) { |
| 153 switch (property) { | 153 switch (property) { |
| 154 case CSSPropertyBackgroundImage: | 154 case CSSPropertyBackgroundImage: |
| 155 case CSSPropertyBackgroundPositionX: | 155 case CSSPropertyBackgroundPositionX: |
| 156 case CSSPropertyBackgroundPositionY: | 156 case CSSPropertyBackgroundPositionY: |
| 157 case CSSPropertyBackgroundSize: | 157 case CSSPropertyBackgroundSize: |
| 158 case CSSPropertyWebkitBackgroundSize: | 158 case CSSPropertyWebkitBackgroundSize: |
| (...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 610 return; | 610 return; |
| 611 case CSSPropertyZoom: | 611 case CSSPropertyZoom: |
| 612 style->setZoom(clampTo<float>(toAnimatableDouble(value)->toDouble(), std
::numeric_limits<float>::denorm_min())); | 612 style->setZoom(clampTo<float>(toAnimatableDouble(value)->toDouble(), std
::numeric_limits<float>::denorm_min())); |
| 613 return; | 613 return; |
| 614 default: | 614 default: |
| 615 ASSERT_NOT_REACHED(); | 615 ASSERT_NOT_REACHED(); |
| 616 } | 616 } |
| 617 } | 617 } |
| 618 | 618 |
| 619 } // namespace WebCore | 619 } // namespace WebCore |
| OLD | NEW |