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

Unified Diff: Source/core/css/StylePropertySerializer.h

Issue 1164573002: CSSValue Immediates: Change CSSValue to an object instead of a pointer (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 5 years, 5 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
« no previous file with comments | « Source/core/css/RuleFeature.cpp ('k') | Source/core/css/StylePropertySerializer.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/StylePropertySerializer.h
diff --git a/Source/core/css/StylePropertySerializer.h b/Source/core/css/StylePropertySerializer.h
index 7743d69f664e74f3fbafde9760ef7a22d8ac8205..310e1b4aec0ac6e0e1f9c457f65732f122ae00ff 100644
--- a/Source/core/css/StylePropertySerializer.h
+++ b/Source/core/css/StylePropertySerializer.h
@@ -65,22 +65,25 @@ private:
, m_isImplicit(property.isImplicit())
, m_isInherited(property.isInherited()) { }
- PropertyValueForSerializer(CSSPropertyID id, const CSSValue* value, bool isImportant)
+ PropertyValueForSerializer(CSSPropertyID id, const CSSValue value, bool isImportant)
: m_value(value)
, m_id(id)
, m_isImportant(isImportant)
- , m_isImplicit(value->isImplicitInitialValue())
- , m_isInherited(value->isInheritedValue()) { }
+ , m_isImplicit(value.isImplicitInitialValue())
+ , m_isInherited(value.isInheritedValue()) { }
CSSPropertyID id() const { return m_id; }
- const CSSValue* value() const { return m_value; }
+ const CSSValue value() const { return m_value; }
bool isImportant() const { return m_isImportant; }
bool isImplicit() const { return m_isImplicit; }
bool isInherited() const { return m_isInherited; }
- bool isValid() const { return m_value; }
+ DEFINE_INLINE_TRACE()
+ {
+ visitor->trace(m_value);
+ }
private:
- const CSSValue* m_value;
+ const CSSValue m_value;
CSSPropertyID m_id;
bool m_isImportant;
bool m_isImplicit;
@@ -95,7 +98,7 @@ private:
PropertyValueForSerializer propertyAt(unsigned index) const;
bool shouldProcessPropertyAt(unsigned index) const;
int findPropertyIndex(CSSPropertyID) const;
- const CSSValue* getPropertyCSSValue(CSSPropertyID) const;
+ const NullableCSSValue getPropertyCSSValue(CSSPropertyID) const;
String getPropertyValue(CSSPropertyID) const;
bool isPropertyImplicit(CSSPropertyID) const;
bool propertyIsImportant(CSSPropertyID) const;
« no previous file with comments | « Source/core/css/RuleFeature.cpp ('k') | Source/core/css/StylePropertySerializer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698