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

Unified Diff: third_party/WebKit/Source/core/css/cssom/InlineStylePropertyMap.cpp

Issue 2036893003: [CSS Typed OM] Rename StyleValue -> CSSStyleValue (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update order of core.gypi Created 4 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: third_party/WebKit/Source/core/css/cssom/InlineStylePropertyMap.cpp
diff --git a/third_party/WebKit/Source/core/css/cssom/InlineStylePropertyMap.cpp b/third_party/WebKit/Source/core/css/cssom/InlineStylePropertyMap.cpp
index 6e542512fcef10a7f1abd05f26cac6d89ddae171..1bbf0f9ee90f43945f0f57d27b9dfa0892b832ad 100644
--- a/third_party/WebKit/Source/core/css/cssom/InlineStylePropertyMap.cpp
+++ b/third_party/WebKit/Source/core/css/cssom/InlineStylePropertyMap.cpp
@@ -39,16 +39,16 @@ Vector<String> InlineStylePropertyMap::getProperties()
return result;
}
-void InlineStylePropertyMap::set(CSSPropertyID propertyID, StyleValueOrStyleValueSequenceOrString& item, ExceptionState& exceptionState)
+void InlineStylePropertyMap::set(CSSPropertyID propertyID, CSSStyleValueOrCSSStyleValueSequenceOrString& item, ExceptionState& exceptionState)
{
- if (item.isStyleValue()) {
- StyleValue* styleValue = item.getAsStyleValue();
+ if (item.isCSSStyleValue()) {
+ CSSStyleValue* styleValue = item.getAsCSSStyleValue();
if (!CSSOMTypes::propertyCanTake(propertyID, *styleValue)) {
exceptionState.throwTypeError("Invalid type for property");
return;
}
m_ownerElement->setInlineStyleProperty(propertyID, styleValue->toCSSValue());
- } else if (item.isStyleValueSequence()) {
+ } else if (item.isCSSStyleValueSequence()) {
if (!CSSPropertyMetadata::propertySupportsMultiple(propertyID)) {
exceptionState.throwTypeError("Property does not support multiple values");
return;
@@ -56,8 +56,8 @@ void InlineStylePropertyMap::set(CSSPropertyID propertyID, StyleValueOrStyleValu
// TODO(meade): This won't always work. Figure out what kind of CSSValueList to create properly.
CSSValueList* valueList = CSSValueList::createSpaceSeparated();
- StyleValueVector styleValueVector = item.getAsStyleValueSequence();
- for (const Member<StyleValue> value : styleValueVector) {
+ StyleValueVector styleValueVector = item.getAsCSSStyleValueSequence();
+ for (const Member<CSSStyleValue> value : styleValueVector) {
if (!CSSOMTypes::propertyCanTake(propertyID, *value)) {
exceptionState.throwTypeError("Invalid type for property");
return;
@@ -74,7 +74,7 @@ void InlineStylePropertyMap::set(CSSPropertyID propertyID, StyleValueOrStyleValu
}
}
-void InlineStylePropertyMap::append(CSSPropertyID propertyID, StyleValueOrStyleValueSequenceOrString& item, ExceptionState& exceptionState)
+void InlineStylePropertyMap::append(CSSPropertyID propertyID, CSSStyleValueOrCSSStyleValueSequenceOrString& item, ExceptionState& exceptionState)
{
if (!CSSPropertyMetadata::propertySupportsMultiple(propertyID)) {
exceptionState.throwTypeError("Property does not support multiple values");
@@ -91,15 +91,15 @@ void InlineStylePropertyMap::append(CSSPropertyID propertyID, StyleValueOrStyleV
return;
}
- if (item.isStyleValue()) {
- StyleValue* styleValue = item.getAsStyleValue();
+ if (item.isCSSStyleValue()) {
+ CSSStyleValue* styleValue = item.getAsCSSStyleValue();
if (!CSSOMTypes::propertyCanTake(propertyID, *styleValue)) {
exceptionState.throwTypeError("Invalid type for property");
return;
}
- cssValueList->append(item.getAsStyleValue()->toCSSValue());
- } else if (item.isStyleValueSequence()) {
- for (StyleValue* styleValue : item.getAsStyleValueSequence()) {
+ cssValueList->append(item.getAsCSSStyleValue()->toCSSValue());
+ } else if (item.isCSSStyleValueSequence()) {
+ for (CSSStyleValue* styleValue : item.getAsCSSStyleValueSequence()) {
if (!CSSOMTypes::propertyCanTake(propertyID, *styleValue)) {
exceptionState.throwTypeError("Invalid type for property");
return;

Powered by Google App Engine
This is Rietveld 408576698