diff options
Diffstat (limited to 'WebCore/css/CSSMutableStyleDeclaration.cpp')
-rw-r--r-- | WebCore/css/CSSMutableStyleDeclaration.cpp | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/WebCore/css/CSSMutableStyleDeclaration.cpp b/WebCore/css/CSSMutableStyleDeclaration.cpp index 38aee50..774a8eb 100644 --- a/WebCore/css/CSSMutableStyleDeclaration.cpp +++ b/WebCore/css/CSSMutableStyleDeclaration.cpp @@ -39,7 +39,6 @@ namespace WebCore { CSSMutableStyleDeclaration::CSSMutableStyleDeclaration() : m_node(0) - , m_variableDependentValueCount(0) , m_strictParsing(false) #ifndef NDEBUG , m_iteratorCount(0) @@ -50,7 +49,6 @@ CSSMutableStyleDeclaration::CSSMutableStyleDeclaration() CSSMutableStyleDeclaration::CSSMutableStyleDeclaration(CSSRule* parent) : CSSStyleDeclaration(parent) , m_node(0) - , m_variableDependentValueCount(0) , m_strictParsing(!parent || parent->useStrictParsing()) #ifndef NDEBUG , m_iteratorCount(0) @@ -58,11 +56,10 @@ CSSMutableStyleDeclaration::CSSMutableStyleDeclaration(CSSRule* parent) { } -CSSMutableStyleDeclaration::CSSMutableStyleDeclaration(CSSRule* parent, const Vector<CSSProperty>& properties, unsigned variableDependentValueCount) +CSSMutableStyleDeclaration::CSSMutableStyleDeclaration(CSSRule* parent, const Vector<CSSProperty>& properties) : CSSStyleDeclaration(parent) , m_properties(properties) , m_node(0) - , m_variableDependentValueCount(variableDependentValueCount) , m_strictParsing(!parent || parent->useStrictParsing()) #ifndef NDEBUG , m_iteratorCount(0) @@ -75,7 +72,6 @@ CSSMutableStyleDeclaration::CSSMutableStyleDeclaration(CSSRule* parent, const Ve CSSMutableStyleDeclaration::CSSMutableStyleDeclaration(CSSRule* parent, const CSSProperty* const * properties, int numProperties) : CSSStyleDeclaration(parent) , m_node(0) - , m_variableDependentValueCount(0) , m_strictParsing(!parent || parent->useStrictParsing()) #ifndef NDEBUG , m_iteratorCount(0) @@ -86,9 +82,7 @@ CSSMutableStyleDeclaration::CSSMutableStyleDeclaration(CSSRule* parent, const CS for (int i = 0; i < numProperties; ++i) { const CSSProperty *property = properties[i]; ASSERT(property); - if (property->value()->isVariableDependentValue()) - m_variableDependentValueCount++; - else if (candidates.contains(property->id())) + if (candidates.contains(property->id())) removeProperty(properties[i]->id(), false); m_properties.append(*property); if (!getPropertyPriority(property->id()) && !property->isImportant()) @@ -471,9 +465,6 @@ String CSSMutableStyleDeclaration::removeProperty(int propertyID, bool notifyCha String value = returnText ? foundProperty->value()->cssText() : String(); - if (foundProperty->value()->isVariableDependentValue()) - m_variableDependentValueCount--; - // A more efficient removal strategy would involve marking entries as empty // and sweeping them when the vector grows too big. m_properties.remove(foundProperty - m_properties.data()); @@ -623,8 +614,6 @@ void CSSMutableStyleDeclaration::addParsedProperties(const CSSProperty* const* p removeProperty(properties[i]->id(), false); ASSERT(properties[i]); m_properties.append(*properties[i]); - if (properties[i]->value()->isVariableDependentValue()) - m_variableDependentValueCount++; } } // FIXME: This probably should have a call to setNeedsStyleRecalc() if something changed. We may also wish to add @@ -835,7 +824,7 @@ PassRefPtr<CSSMutableStyleDeclaration> CSSMutableStyleDeclaration::makeMutable() PassRefPtr<CSSMutableStyleDeclaration> CSSMutableStyleDeclaration::copy() const { - return adoptRef(new CSSMutableStyleDeclaration(0, m_properties, m_variableDependentValueCount)); + return adoptRef(new CSSMutableStyleDeclaration(0, m_properties)); } const CSSProperty* CSSMutableStyleDeclaration::findPropertyWithId(int propertyID) const |