OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 CSSSyntaxDescriptor_h | 5 #ifndef CSSSyntaxDescriptor_h |
6 #define CSSSyntaxDescriptor_h | 6 #define CSSSyntaxDescriptor_h |
7 | 7 |
8 #include "core/animation/InterpolationTypesMap.h" | |
9 #include "core/css/parser/CSSParserTokenRange.h" | 8 #include "core/css/parser/CSSParserTokenRange.h" |
10 | 9 |
11 namespace blink { | 10 namespace blink { |
12 | 11 |
13 class CSSParserContext; | 12 class CSSParserContext; |
14 class CSSValue; | 13 class CSSValue; |
15 | 14 |
16 enum class CSSSyntaxType { | 15 enum class CSSSyntaxType { |
17 TokenStream, | 16 TokenStream, |
18 Ident, | 17 Ident, |
(...skipping 27 matching lines...) Expand all Loading... |
46 | 45 |
47 const CSSValue* parse(CSSParserTokenRange, | 46 const CSSValue* parse(CSSParserTokenRange, |
48 const CSSParserContext*, | 47 const CSSParserContext*, |
49 bool isAnimationTainted) const; | 48 bool isAnimationTainted) const; |
50 bool isValid() const { return !m_syntaxComponents.isEmpty(); } | 49 bool isValid() const { return !m_syntaxComponents.isEmpty(); } |
51 bool isTokenStream() const { | 50 bool isTokenStream() const { |
52 return m_syntaxComponents.size() == 1 && | 51 return m_syntaxComponents.size() == 1 && |
53 m_syntaxComponents[0].m_type == CSSSyntaxType::TokenStream; | 52 m_syntaxComponents[0].m_type == CSSSyntaxType::TokenStream; |
54 } | 53 } |
55 | 54 |
56 InterpolationTypes createInterpolationTypes( | |
57 const AtomicString& propertyName) const; | |
58 | |
59 private: | 55 private: |
60 Vector<CSSSyntaxComponent> m_syntaxComponents; | 56 Vector<CSSSyntaxComponent> m_syntaxComponents; |
61 }; | 57 }; |
62 | 58 |
63 } // namespace blink | 59 } // namespace blink |
64 | 60 |
65 #endif // CSSSyntaxDescriptor_h | 61 #endif // CSSSyntaxDescriptor_h |
OLD | NEW |