#include "HTMLInputElement.h"
#include "KeyboardEvent.h"
#include "RenderTextControlSingleLine.h"
+#include "TextEvent.h"
#include <wtf/text/WTFString.h>
namespace WebCore {
return true;
}
+bool TextFieldInputType::shouldSubmitImplicitly(Event* event)
+{
+ return (event->type() == eventNames().textInputEvent && event->isTextEvent() && static_cast<TextEvent*>(event)->data() == "\n") || InputType::shouldSubmitImplicitly(event);
+}
+
RenderObject* TextFieldInputType::createRenderer(RenderArena* arena, RenderStyle*) const
{
return new (arena) RenderTextControlSingleLine(element(), element()->placeholderShouldBeVisible());