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

Unified Diff: Source/core/css/StylePropertySerializer.cpp

Issue 16736004: Stylesheet rule.cssText of content property should be quoted when the value is string. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 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
« no previous file with comments | « Source/core/css/CSSValueList.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/StylePropertySerializer.cpp
diff --git a/Source/core/css/StylePropertySerializer.cpp b/Source/core/css/StylePropertySerializer.cpp
index c132da45ddbc2c6dbeede66d8e29d865555f4c19..d987e9ed9918cf9bd59b2c4e7f117f8f89567f07 100644
--- a/Source/core/css/StylePropertySerializer.cpp
+++ b/Source/core/css/StylePropertySerializer.cpp
@@ -86,6 +86,10 @@ String StylePropertySerializer::asText() const
case CSSPropertyBackgroundRepeatY:
repeatYPropertyIndex = n;
continue;
+ case CSSPropertyContent:
+ if (property.value()->isValueList())
+ value = toCSSValueList(property.value())->customCssText(AlwaysQuoteCSSString);
+ break;
case CSSPropertyBorderTopWidth:
case CSSPropertyBorderRightWidth:
case CSSPropertyBorderBottomWidth:
@@ -215,8 +219,10 @@ String StylePropertySerializer::asText() const
}
if (!value.isNull()) {
- propertyID = shorthandPropertyID;
- shorthandPropertyUsed.set(shortPropertyIndex);
+ if (shorthandPropertyID) {
+ propertyID = shorthandPropertyID;
+ shorthandPropertyUsed.set(shortPropertyIndex);
+ }
} else
value = property.value()->cssText();
« no previous file with comments | « Source/core/css/CSSValueList.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698