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

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

Issue 2042943003: Move CSSValue->CSSStyleValue logic out of StylePropertyMap and into the StyleValueFactory. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@stylevaue
Patch Set: 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/CSSStyleValue.cpp
diff --git a/third_party/WebKit/Source/core/css/cssom/CSSStyleValue.cpp b/third_party/WebKit/Source/core/css/cssom/CSSStyleValue.cpp
index 9be68ea08c3e2443960e51c05c6a9c2748cf6cfd..021d150affa1df401ec5ccce9f73a44aea1a5f23 100644
--- a/third_party/WebKit/Source/core/css/cssom/CSSStyleValue.cpp
+++ b/third_party/WebKit/Source/core/css/cssom/CSSStyleValue.cpp
@@ -34,11 +34,11 @@ ScriptValue CSSStyleValue::parse(ScriptState* scriptState, const String& propert
if (!cssValue)
return ScriptValue::createNull(scriptState);
- CSSStyleValue* styleValue = StyleValueFactory::create(propertyID, *cssValue);
- if (!styleValue)
+ CSSStyleValueVector styleValueVector = StyleValueFactory::cssValueToStyleValueVector(propertyID, *cssValue);
+ if (styleValueVector.size() != 1)
Timothy Loh 2016/06/08 04:19:17 should put a TODO to handle this case
meade_UTC10 2016/06/08 07:13:16 Done.
return ScriptValue::createNull(scriptState);
- v8::Local<v8::Value> wrappedValue = toV8(styleValue, scriptState->context()->Global(), scriptState->isolate());
+ v8::Local<v8::Value> wrappedValue = toV8(styleValueVector[0], scriptState->context()->Global(), scriptState->isolate());
return ScriptValue(scriptState, wrappedValue);
}

Powered by Google App Engine
This is Rietveld 408576698