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

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

Issue 18311002: Partial implementation of CSSVariablesMap for CSS Variables CSSOM (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Removed unused IDL callback definition Created 7 years, 6 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: Source/core/css/StylePropertySet.h
diff --git a/Source/core/css/StylePropertySet.h b/Source/core/css/StylePropertySet.h
index 3fed4302f2db09da3ccb9aca97bd3c3cb4db6ddb..50575dc9b178a1173df6eeb77f4d36d1414b43c3 100644
--- a/Source/core/css/StylePropertySet.h
+++ b/Source/core/css/StylePropertySet.h
@@ -41,6 +41,8 @@ class PropertySetCSSStyleDeclaration;
class StylePropertyShorthand;
class StyleSheetContents;
+typedef int ExceptionCode;
+
class StylePropertySet : public RefCounted<StylePropertySet> {
friend class PropertyReference;
public:
@@ -85,9 +87,13 @@ public:
bool isEmpty() const;
PropertyReference propertyAt(unsigned index) const { return PropertyReference(*this, index); }
int findPropertyIndex(CSSPropertyID) const;
+ size_t findVariableIndex(const AtomicString& name) const;
PassRefPtr<CSSValue> getPropertyCSSValue(CSSPropertyID) const;
String getPropertyValue(CSSPropertyID) const;
+ unsigned variableCount() const;
+ String variableValue(const AtomicString& name) const;
+
bool propertyIsImportant(CSSPropertyID) const;
CSSPropertyID getPropertyShorthand(CSSPropertyID) const;
bool isPropertyImplicit(CSSPropertyID) const;
@@ -197,6 +203,7 @@ public:
void appendPrefixingVariantProperty(const CSSProperty&);
void setPrefixingVariantProperty(const CSSProperty&);
void setProperty(const CSSProperty&, CSSProperty* slot = 0);
+ bool setVariableValue(const AtomicString& name, const String& value, ExceptionCode&, bool important = false);
bool removeProperty(CSSPropertyID, String* returnText = 0);
void removePrefixedOrUnprefixedProperty(CSSPropertyID);
@@ -204,6 +211,8 @@ public:
bool removePropertiesInSet(const CSSPropertyID* set, unsigned length);
void removeEquivalentProperties(const StylePropertySet*);
void removeEquivalentProperties(const CSSStyleDeclaration*);
+ bool removeVariable(const AtomicString& name);
+ bool clearVariables();
void mergeAndOverrideOnConflict(const StylePropertySet*);

Powered by Google App Engine
This is Rietveld 408576698