Index: Source/core/rendering/RenderMenuList.cpp |
diff --git a/Source/core/rendering/RenderMenuList.cpp b/Source/core/rendering/RenderMenuList.cpp |
index dfeadb9c88443fa2914929bf8de9c0fd2b528fd6..a6bfa77f08a335e26cc49d4206ebeb33c8f189cc 100644 |
--- a/Source/core/rendering/RenderMenuList.cpp |
+++ b/Source/core/rendering/RenderMenuList.cpp |
@@ -116,13 +116,7 @@ void RenderMenuList::adjustInnerStyle() |
innerStyle->setPaddingTop(Length(theme()->popupInternalPaddingTop(style()), Fixed)); |
innerStyle->setPaddingBottom(Length(theme()->popupInternalPaddingBottom(style()), Fixed)); |
- if (document()->page()->chrome()->selectItemWritingDirectionIsNatural()) { |
- // Items in the popup will not respect the CSS text-align and direction properties, |
- // so we must adjust our own style to match. |
- innerStyle->setTextAlign(LEFT); |
- TextDirection direction = (m_buttonText && m_buttonText->text()->defaultWritingDirection() == WTF::Unicode::RightToLeft) ? RTL : LTR; |
- innerStyle->setDirection(direction); |
- } else if (m_optionStyle && document()->page()->chrome()->selectItemAlignmentFollowsMenuWritingDirection()) { |
+ if (m_optionStyle) { |
if ((m_optionStyle->direction() != innerStyle->direction() || m_optionStyle->unicodeBidi() != innerStyle->unicodeBidi())) |
m_innerBlock->setNeedsLayoutAndPrefWidthsRecalc(); |
innerStyle->setTextAlign(style()->isLeftToRightDirection() ? LEFT : RIGHT); |