Index: third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp |
diff --git a/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp b/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp |
index 346846a93476fd69ec567ee82784ea8c5b029b88..3d14c1f5d1f6c20b4739b62a133124565f569e65 100644 |
--- a/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp |
+++ b/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp |
@@ -619,13 +619,9 @@ void StyleResolver::matchAllRules(StyleResolverState& state, ElementRuleCollecto |
// after all attributes, since their mapped style depends on the values of multiple attributes. |
collector.addElementStyleProperties(state.element()->additionalPresentationAttributeStyle()); |
- if (state.element()->isHTMLElement()) { |
- bool isAuto; |
- TextDirection textDirection = toHTMLElement(state.element())->directionalityIfhasDirAutoAttribute(isAuto); |
- if (isAuto) { |
- state.setHasDirAutoAttribute(true); |
- collector.addElementStyleProperties(textDirection == LTR ? leftToRightDeclaration() : rightToLeftDeclaration()); |
- } |
+ if (state.element()->isHTMLElement() && toHTMLElement(state.element())->hasDirectionAuto()) { |
+ state.setHasDirAutoAttribute(true); |
+ collector.addElementStyleProperties(state.element()->directionality() == LTR ? leftToRightDeclaration() : rightToLeftDeclaration()); |
} |
} |