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

Unified Diff: Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl

Issue 1225553002: CSSValue Immediates: Make CSSPrimitiveValue a container (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@cssvalue_patch_1
Patch Set: Rebase Created 5 years, 5 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 | « no previous file | Source/core/animation/CSSValueInterpolationType.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl
diff --git a/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl b/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl
index c25ed31b0e276f1850137f0f6c38d5962f17f3ba..e3cb394e2959d9ce5f63215fd7eaecb803618db5 100644
--- a/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl
+++ b/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl
@@ -142,7 +142,7 @@ namespace blink {
if (!value.isPrimitiveValue())
return;
- CSSPrimitiveValue& primitiveValue = toCSSPrimitiveValue(value);
+ CSSPrimitiveValue primitiveValue = toCSSPrimitiveValue(value);
if (primitiveValue.getValueID() == {{auto_identity}})
state.style()->{{auto_setter}}();
else
@@ -358,8 +358,8 @@ static bool borderImageLengthMatchesAllSides(const BorderImageLengthBox& borderI
if (!pair || !pair->first() || !pair->second())
continue;
- AtomicString identifier(pair->first()->getStringValue());
- int value = pair->second()->getIntValue();
+ AtomicString identifier(toCSSPrimitiveValue(*pair->first()).getStringValue());
+ int value = toCSSPrimitiveValue(*pair->second()).getIntValue();
CounterDirectives& directives = map.add(identifier, CounterDirectives()).storedValue->value;
{% if action == 'Reset' %}
directives.setResetValue(value);
@@ -520,7 +520,7 @@ static bool borderImageLengthMatchesAllSides(const BorderImageLengthBox& borderI
if (!list.item(0).isPrimitiveValue())
return;
- CSSPrimitiveValue& primitiveValue = toCSSPrimitiveValue(list.item(0));
+ CSSPrimitiveValue primitiveValue = toCSSPrimitiveValue(list.item(0));
if (!primitiveValue.isURI())
return;
@@ -528,7 +528,7 @@ static bool borderImageLengthMatchesAllSides(const BorderImageLengthBox& borderI
value = list.item(1);
}
if (value.isPrimitiveValue()) {
- CSSPrimitiveValue& primitiveValue = toCSSPrimitiveValue(value);
+ CSSPrimitiveValue primitiveValue = toCSSPrimitiveValue(value);
Color color;
SVGPaintType paintType = SVG_PAINTTYPE_RGBCOLOR;
if (primitiveValue.getValueID() == CSSValueNone) {
« no previous file with comments | « no previous file | Source/core/animation/CSSValueInterpolationType.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698