Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 #ifndef CSSTokenStreamValue_h | |
| 2 #define CSSTokenStreamValue_h | |
| 3 | |
| 4 #include "bindings/core/v8/Iterable.h" | |
| 5 #include "bindings/core/v8/ScriptWrappable.h" | |
| 6 #include "core/CSSPropertyNames.h" | |
| 7 #include "core/CoreExport.h" | |
| 8 #include "core/css/CSSCustomIdentValue.h" | |
| 9 #include "core/css/CSSPrimitiveValue.h" | |
| 10 #include "core/css/cssom/CSSStyleValue.h" | |
| 11 #include "core/css/parser/CSSParserTokenRange.h" | |
| 12 #include "core/css/parser/CSSPropertyParser.h" | |
| 13 #include "platform/heap/HeapAllocator.h" | |
| 14 #include "wtf/Vector.h" | |
| 15 | |
| 16 namespace blink { | |
| 17 | |
| 18 class CORE_EXPORT CSSTokenStreamValueObserver : public GarbageCollectedMixin { | |
|
meade_UTC10
2016/07/07 05:48:02
What's this class for? It doesn't seem to be used
anthonyhkf
2016/07/07 08:01:45
Done.
| |
| 19 public: | |
| 20 virtual void valueWasSet() = 0; | |
| 21 | |
| 22 DEFINE_INLINE_VIRTUAL_TRACE() { } | |
| 23 }; | |
| 24 | |
| 25 class CORE_EXPORT CSSTokenStreamValue final : public CSSStyleValue, | |
| 26 public ValueIterable<String> { | |
|
meade_UTC10
2016/07/07 05:48:02
This can be on the previous line (blink doesn't ha
anthonyhkf
2016/07/07 08:01:45
Done.
| |
| 27 WTF_MAKE_NONCOPYABLE(CSSTokenStreamValue); | |
| 28 DEFINE_WRAPPERTYPEINFO(); | |
| 29 public: | |
| 30 static CSSTokenStreamValue* create(const Vector<String>& listOfReferences) | |
| 31 { | |
| 32 return new CSSTokenStreamValue(listOfReferences); | |
| 33 } | |
| 34 | |
| 35 CSSValue* toCSSValue() const override; | |
| 36 | |
| 37 StyleValueType type() const override { return TokenStreamType; } | |
| 38 | |
| 39 String componentAtIndex(int index) { return m_listOfReferences.at(index); } | |
|
meade_UTC10
2016/07/07 05:48:02
Can this be renamed to referenceAtIndex or somethi
anthonyhkf
2016/07/07 08:01:45
Done.
| |
| 40 | |
| 41 Vector<String> listOfReferences() const { return m_listOfReferences; } | |
|
meade_UTC10
2016/07/07 05:48:02
Is this function used anywhere?
anthonyhkf
2016/07/07 08:01:45
Done.
| |
| 42 | |
| 43 size_t size() { return m_listOfReferences.size(); } | |
| 44 | |
| 45 protected: | |
| 46 CSSTokenStreamValue(Vector<String> listOfReferences) : CSSStyleValue(), | |
| 47 m_listOfReferences(listOfReferences) { } | |
|
meade_UTC10
2016/07/07 05:48:02
Constructor line breaking should be like this:
My
anthonyhkf
2016/07/07 08:01:45
Done.
| |
| 48 | |
| 49 private: | |
| 50 IterationSource* startIteration(ScriptState*, ExceptionState&) override; | |
| 51 | |
| 52 Vector<String> m_listOfReferences; | |
| 53 }; | |
| 54 | |
| 55 } // namespace blink | |
| 56 | |
| 57 #endif // CSSTokenStreamValue_h | |
| OLD | NEW |