| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef InterpolableValue_h | 5 #ifndef InterpolableValue_h |
| 6 #define InterpolableValue_h | 6 #define InterpolableValue_h |
| 7 | 7 |
| 8 #include "core/animation/animatable/AnimatableValue.h" | 8 #include "core/animation/animatable/AnimatableValue.h" |
| 9 #include "wtf/OwnPtr.h" | 9 #include "wtf/OwnPtr.h" |
| 10 #include "wtf/PassOwnPtr.h" | 10 #include "wtf/PassOwnPtr.h" |
| 11 #include "wtf/Vector.h" | 11 #include "wtf/Vector.h" |
| 12 | 12 |
| 13 namespace blink { | 13 namespace blink { |
| 14 | 14 |
| 15 class InterpolableValue : public DummyBase<InterpolableValue> { | 15 class InterpolableValue { |
| 16 DECLARE_EMPTY_VIRTUAL_DESTRUCTOR_WILL_BE_REMOVED(InterpolableValue); | 16 DECLARE_EMPTY_VIRTUAL_DESTRUCTOR_WILL_BE_REMOVED(InterpolableValue); |
| 17 public: | 17 public: |
| 18 virtual bool isNumber() const { return false; } | 18 virtual bool isNumber() const { return false; } |
| 19 virtual bool isBool() const { return false; } | 19 virtual bool isBool() const { return false; } |
| 20 virtual bool isList() const { return false; } | 20 virtual bool isList() const { return false; } |
| 21 virtual bool isAnimatableValue() const { return false; } | 21 virtual bool isAnimatableValue() const { return false; } |
| 22 | 22 |
| 23 virtual PassOwnPtr<InterpolableValue> clone() const = 0; | 23 virtual PassOwnPtr<InterpolableValue> clone() const = 0; |
| 24 | 24 |
| 25 virtual void trace(Visitor*) { } | 25 virtual void trace(Visitor*) { } |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 158 }; | 158 }; |
| 159 | 159 |
| 160 DEFINE_TYPE_CASTS(InterpolableNumber, InterpolableValue, value, value->isNumber(
), value.isNumber()); | 160 DEFINE_TYPE_CASTS(InterpolableNumber, InterpolableValue, value, value->isNumber(
), value.isNumber()); |
| 161 DEFINE_TYPE_CASTS(InterpolableBool, InterpolableValue, value, value->isBool(), v
alue.isBool()); | 161 DEFINE_TYPE_CASTS(InterpolableBool, InterpolableValue, value, value->isBool(), v
alue.isBool()); |
| 162 DEFINE_TYPE_CASTS(InterpolableList, InterpolableValue, value, value->isList(), v
alue.isList()); | 162 DEFINE_TYPE_CASTS(InterpolableList, InterpolableValue, value, value->isList(), v
alue.isList()); |
| 163 DEFINE_TYPE_CASTS(InterpolableAnimatableValue, InterpolableValue, value, value->
isAnimatableValue(), value.isAnimatableValue()); | 163 DEFINE_TYPE_CASTS(InterpolableAnimatableValue, InterpolableValue, value, value->
isAnimatableValue(), value.isAnimatableValue()); |
| 164 | 164 |
| 165 } | 165 } |
| 166 | 166 |
| 167 #endif | 167 #endif |
| OLD | NEW |