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

Unified Diff: third_party/WebKit/Source/core/css/parser/CSSParserImpl.cpp

Issue 2624213004: Fix setting css-wide keywords on registered custom properties (Closed)
Patch Set: 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
« no previous file with comments | « third_party/WebKit/LayoutTests/custom-properties/registered-property-cssom.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/css/parser/CSSParserImpl.cpp
diff --git a/third_party/WebKit/Source/core/css/parser/CSSParserImpl.cpp b/third_party/WebKit/Source/core/css/parser/CSSParserImpl.cpp
index 56c252edc71bf0f05bcb6bc5fd9340c87efd9e6d..a6549ffef62e597e8f60d5a229faba1c351ebaab 100644
--- a/third_party/WebKit/Source/core/css/parser/CSSParserImpl.cpp
+++ b/third_party/WebKit/Source/core/css/parser/CSSParserImpl.cpp
@@ -81,7 +81,9 @@ MutableStylePropertySet::SetResult CSSParserImpl::parseVariableValue(
bool didParse = false;
bool didChange = false;
if (!parser.m_parsedProperties.isEmpty()) {
- if (registry) {
+ const CSSCustomPropertyDeclaration* parsedDeclaration =
+ toCSSCustomPropertyDeclaration(parser.m_parsedProperties[0].value());
+ if (parsedDeclaration->value() && registry) {
const PropertyRegistry::Registration* registration =
registry->registration(propertyName);
// TODO(timloh): This is a bit wasteful, we parse the registered property
« no previous file with comments | « third_party/WebKit/LayoutTests/custom-properties/registered-property-cssom.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698