Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1266)

Unified Diff: third_party/WebKit/Source/core/css/CSSValue.h

Issue 2346193002: Split CSSPrimitiveValue into CSSPrimitiveValue and CSSIdentifierValue (Closed)
Patch Set: Rebase please work Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/css/CSSValue.h
diff --git a/third_party/WebKit/Source/core/css/CSSValue.h b/third_party/WebKit/Source/core/css/CSSValue.h
index e2346ca3359c0359a6a32a03bd586004b15b3923..781c73feb2a910150f29b197b680758d3cf31385 100644
--- a/third_party/WebKit/Source/core/css/CSSValue.h
+++ b/third_party/WebKit/Source/core/css/CSSValue.h
@@ -27,6 +27,8 @@
namespace blink {
+class Length;
+
class CORE_EXPORT CSSValue : public GarbageCollectedFinalized<CSSValue> {
public:
// Override operator new to allocate CSSValue subtype objects onto
@@ -43,9 +45,13 @@ public:
return ThreadHeap::allocateOnArenaIndex(state, size, isEager ? BlinkGC::EagerSweepArenaIndex : BlinkGC::CSSValueArenaIndex, GCInfoTrait<CSSValue>::index(), typeName);
}
+ // TODO(sashab): Remove this method and move logic to the caller.
+ static CSSValue* create(const Length& value, float zoom);
+
String cssText() const;
bool isPrimitiveValue() const { return m_classType == PrimitiveClass; }
+ bool isIdentifierValue() const { return m_classType == IdentifierClass; }
bool isValuePair() const { return m_classType == ValuePairClass; }
bool isValueList() const { return m_classType >= ValueListClass; }
@@ -114,6 +120,7 @@ protected:
static const size_t ClassTypeBits = 6;
enum ClassType {
PrimitiveClass,
+ IdentifierClass,
ColorClass,
CounterClass,
QuadClass,
« no previous file with comments | « third_party/WebKit/Source/core/css/CSSShadowValue.cpp ('k') | third_party/WebKit/Source/core/css/CSSValue.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698