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

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

Issue 22336008: Use the runtime flag and remove '-webkit-' prefix for CSS3 text-indent. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: patch Created 7 years, 4 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: Source/core/css/resolver/StyleBuilderCustom.cpp
diff --git a/Source/core/css/resolver/StyleBuilderCustom.cpp b/Source/core/css/resolver/StyleBuilderCustom.cpp
index 59372a39a4468f9d0bd9084d0db2b58691b21dbc..da9cbdb13c6e455227e70e1ecb92fa8855557cdc 100644
--- a/Source/core/css/resolver/StyleBuilderCustom.cpp
+++ b/Source/core/css/resolver/StyleBuilderCustom.cpp
@@ -516,17 +516,13 @@ void StyleBuilderFunctions::applyValueCSSPropertyTextDecoration(StyleResolverSta
void StyleBuilderFunctions::applyInheritCSSPropertyTextIndent(StyleResolverState& state)
{
state.style()->setTextIndent(state.parentStyle()->textIndent());
-#if ENABLE(CSS3_TEXT)
state.style()->setTextIndentLine(state.parentStyle()->textIndentLine());
-#endif
}
void StyleBuilderFunctions::applyInitialCSSPropertyTextIndent(StyleResolverState& state)
{
state.style()->setTextIndent(RenderStyle::initialTextIndent());
-#if ENABLE(CSS3_TEXT)
state.style()->setTextIndentLine(RenderStyle::initialTextIndentLine());
-#endif
}
void StyleBuilderFunctions::applyValueCSSPropertyTextIndent(StyleResolverState& state, CSSValue* value)
@@ -534,9 +530,9 @@ void StyleBuilderFunctions::applyValueCSSPropertyTextIndent(StyleResolverState&
if (!value->isValueList())
return;
- // [ <length> | <percentage> ] -webkit-each-line
+ // [ <length> | <percentage> ] each-line
// The order is guaranteed. See CSSParser::parseTextIndent.
- // The second value, -webkit-each-line is handled only when CSS3_TEXT is enabled.
+ // The second value, each-line is handled only when css3TextEnabled() returns true.
CSSValueList* valueList = toCSSValueList(value);
CSSPrimitiveValue* primitiveValue = toCSSPrimitiveValue(valueList->itemWithoutBoundsCheck(0));
@@ -544,16 +540,12 @@ void StyleBuilderFunctions::applyValueCSSPropertyTextIndent(StyleResolverState&
ASSERT(!lengthOrPercentageValue.isUndefined());
state.style()->setTextIndent(lengthOrPercentageValue);
-#if ENABLE(CSS3_TEXT)
- ASSERT(valueList->length() <= 2);
Julien - ping for review 2013/08/21 23:54:50 This ASSERT is still valid AFAICT so we should kee
jaehun 2013/08/22 02:04:39 Umm... I agree. I'll recover ASSERT.
CSSPrimitiveValue* eachLineValue = toCSSPrimitiveValue(valueList->item(1));
if (eachLineValue) {
- ASSERT(eachLineValue->getValueID() == CSSValueWebkitEachLine);
+ ASSERT(eachLineValue->getValueID() == CSSValueEachLine);
state.style()->setTextIndentLine(TextIndentEachLine);
- } else {
+ } else
state.style()->setTextIndentLine(TextIndentFirstLine);
- }
-#endif
}
void StyleBuilderFunctions::applyValueCSSPropertyVerticalAlign(StyleResolverState& state, CSSValue* value)

Powered by Google App Engine
This is Rietveld 408576698