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

Unified Diff: third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp

Issue 2032243003: Make CSSValueList store const CSSValues (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@_make_computedstyledeclaration_return_const
Patch Set: Small fix n CSSOM 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/resolver/StyleBuilderCustom.cpp
diff --git a/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp b/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
index 8094ce5a89ce589cf90a76a25338a49c68e21ea0..5afc5c6072c7a6c65f50e66f3cbb9de2524fe8cb 100644
--- a/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
+++ b/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
@@ -474,7 +474,7 @@ void StyleBuilderFunctions::applyValueCSSPropertyTextIndent(StyleResolverState&
TextIndentType textIndentTypeValue = ComputedStyle::initialTextIndentType();
for (auto& listValue : toCSSValueList(value)) {
- CSSPrimitiveValue* primitiveValue = toCSSPrimitiveValue(listValue.get());
+ const CSSPrimitiveValue* primitiveValue = toCSSPrimitiveValue(listValue.get());
if (!primitiveValue->getValueID())
lengthOrPercentageValue = primitiveValue->convertToLength(state.cssToLengthConversionData());
else if (primitiveValue->getValueID() == CSSValueEachLine)
@@ -702,7 +702,7 @@ void StyleBuilderFunctions::applyValueCSSPropertyContent(StyleResolverState& sta
if (item->isImageGeneratorValue() || item->isImageSetValue() || item->isImageValue()) {
nextContent = ContentData::create(state.styleImage(CSSPropertyContent, *item));
} else if (item->isCounterValue()) {
- CSSCounterValue* counterValue = toCSSCounterValue(item.get());
+ const CSSCounterValue* counterValue = toCSSCounterValue(item.get());
EListStyleType listStyleType = NoneListStyle;
CSSValueID listStyleIdent = counterValue->listStyle();
if (listStyleIdent != CSSValueNone)
@@ -731,7 +731,7 @@ void StyleBuilderFunctions::applyValueCSSPropertyContent(StyleResolverState& sta
} else {
String string;
if (item->isFunctionValue()) {
- CSSFunctionValue* functionValue = toCSSFunctionValue(item.get());
+ const CSSFunctionValue* functionValue = toCSSFunctionValue(item.get());
DCHECK_EQ(functionValue->functionType(), CSSValueAttr);
// FIXME: Can a namespace be specified for an attr(foo)?
if (state.style()->styleType() == PseudoIdNone)

Powered by Google App Engine
This is Rietveld 408576698