Index: Source/WebCore/html/BaseMultipleFieldsDateAndTimeInputType.cpp |
=================================================================== |
--- Source/WebCore/html/BaseMultipleFieldsDateAndTimeInputType.cpp (revision 141524) |
+++ Source/WebCore/html/BaseMultipleFieldsDateAndTimeInputType.cpp (working copy) |
@@ -195,14 +195,10 @@ |
void BaseMultipleFieldsDateAndTimeInputType::createShadowSubtree() |
{ |
- DEFINE_STATIC_LOCAL(AtomicString, dateAndTimeInputContainerPseudoId, ("-webkit-date-and-time-container", AtomicString::ConstructFromLiteral)); |
- |
ASSERT(element()->shadow()); |
Document* document = element()->document(); |
- RefPtr<HTMLDivElement> container = HTMLDivElement::create(document); |
- element()->userAgentShadowRoot()->appendChild(container); |
- container->setPseudo(dateAndTimeInputContainerPseudoId); |
+ ContainerNode* container = element()->userAgentShadowRoot(); |
RefPtr<DateTimeEditElement> dateTimeEditElement(DateTimeEditElement::create(document, *this)); |
m_dateTimeEditElement = dateTimeEditElement.get(); |
@@ -350,6 +346,11 @@ |
} |
} |
+bool BaseMultipleFieldsDateAndTimeInputType::shouldApplyLocaleDirection() const |
+{ |
+ return true; |
+} |
+ |
bool BaseMultipleFieldsDateAndTimeInputType::shouldUseInputMethod() const |
{ |
return false; |
@@ -365,10 +366,6 @@ |
if (!m_dateTimeEditElement) |
return; |
- AtomicString direction = element()->locale().isRTL() ? AtomicString("rtl", AtomicString::ConstructFromLiteral) : AtomicString("ltr", AtomicString::ConstructFromLiteral); |
- if (Element* container = ElementTraversal::firstWithin(element()->userAgentShadowRoot())) |
- container->setAttribute(HTMLNames::dirAttr, direction); |
- |
DateTimeEditElement::LayoutParameters layoutParameters(element()->locale(), createStepRange(AnyIsDefaultStep)); |
DateComponents date; |