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

Unified Diff: third_party/WebKit/Source/core/css/PropertyRegistration.cpp

Issue 2622403006: Compute initial values for registered custom properties. (Closed)
Patch Set: initialise CSSToLengthConversionData nicer Created 3 years, 11 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/PropertyRegistration.cpp
diff --git a/third_party/WebKit/Source/core/css/PropertyRegistration.cpp b/third_party/WebKit/Source/core/css/PropertyRegistration.cpp
index ed25ec77536f94dced75c8e13c3f68c4ab15d0a5..09683e1c9aeaa4f83c527fc7a5df85ad74e54dc3 100644
--- a/third_party/WebKit/Source/core/css/PropertyRegistration.cpp
+++ b/third_party/WebKit/Source/core/css/PropertyRegistration.cpp
@@ -12,6 +12,7 @@
#include "core/css/PropertyRegistry.h"
#include "core/css/parser/CSSTokenizer.h"
#include "core/css/parser/CSSVariableParser.h"
+#include "core/css/resolver/StyleBuilderConverter.h"
#include "core/dom/Document.h"
#include "core/dom/ExceptionCode.h"
#include "core/dom/StyleChangeReason.h"
@@ -121,6 +122,8 @@ void PropertyRegistration::registerProperty(
"The initial value provided is not computationally independent.");
return;
}
+ initial =
+ &StyleBuilderConverter::convertRegisteredPropertyInitialValue(*initial);
RefPtr<CSSVariableData> initialVariableData = CSSVariableData::create(
tokenizer.tokenRange(), isAnimationTainted, false);
registry.registerProperty(

Powered by Google App Engine
This is Rietveld 408576698