OLD | NEW |
1 #ifndef StyleValue_h | 1 #ifndef StyleValue_h |
2 #define StyleValue_h | 2 #define StyleValue_h |
3 | 3 |
4 #include "bindings/core/v8/ScriptWrappable.h" | 4 #include "bindings/core/v8/ScriptWrappable.h" |
5 #include "core/CoreExport.h" | 5 #include "core/CoreExport.h" |
6 #include "core/css/CSSValue.h" | 6 #include "core/css/CSSValue.h" |
7 #include "core/css/CSSValuePool.h" | 7 #include "core/css/CSSValuePool.h" |
8 | 8 |
9 namespace blink { | 9 namespace blink { |
10 | 10 |
11 class ScriptState; | 11 class ScriptState; |
12 class ScriptValue; | 12 class ScriptValue; |
13 | 13 |
14 class CORE_EXPORT StyleValue : public RefCountedWillBeGarbageCollectedFinalized<
StyleValue>, public ScriptWrappable { | 14 class CORE_EXPORT StyleValue : public RefCountedWillBeGarbageCollectedFinalized<
StyleValue>, public ScriptWrappable { |
15 DEFINE_WRAPPERTYPEINFO(); | 15 DEFINE_WRAPPERTYPEINFO(); |
16 | 16 |
17 public: | 17 public: |
18 enum StyleValueType { | 18 enum StyleValueType { |
19 KeywordValueType, SimpleLengthType, CalcLengthType, NumberType | 19 KeywordValueType, SimpleLengthType, CalcLengthType, NumberType |
20 }; | 20 }; |
21 | 21 |
22 virtual StyleValueType type() const = 0; | 22 virtual StyleValueType type() const = 0; |
23 | 23 |
24 static PassRefPtrWillBeRawPtr<StyleValue> create(const CSSValue&); | 24 static PassRefPtrWillBeRawPtr<StyleValue> create(const CSSValue&); |
25 static ScriptValue parse(ScriptState*, const String& property, const String&
cssText); | 25 static ScriptValue parse(ScriptState*, const String& property, const String&
cssText); |
26 | 26 |
27 virtual const String& cssString() const = 0; | 27 virtual const String& cssString() const = 0; |
28 virtual PassRefPtrWillBeRawPtr<CSSValue> toCSSValue() = 0; | 28 virtual PassRefPtrWillBeRawPtr<CSSValue> toCSSValue() = 0; |
29 | 29 |
| 30 DEFINE_INLINE_VIRTUAL_TRACE() { } |
| 31 |
30 protected: | 32 protected: |
31 StyleValue() {} | 33 StyleValue() {} |
32 }; | 34 }; |
33 | 35 |
34 } // namespace blink | 36 } // namespace blink |
35 | 37 |
36 #endif | 38 #endif |
OLD | NEW |