Index: third_party/WebKit/Source/core/html/forms/BaseButtonInputType.cpp |
diff --git a/third_party/WebKit/Source/core/html/forms/BaseButtonInputType.cpp b/third_party/WebKit/Source/core/html/forms/BaseButtonInputType.cpp |
index 9eb0bbaf3e4c91e2a48d2369d6d9f5453b6e3163..c5f1fb7499431a2c4541763cf7bfa8686df0967a 100644 |
--- a/third_party/WebKit/Source/core/html/forms/BaseButtonInputType.cpp |
+++ b/third_party/WebKit/Source/core/html/forms/BaseButtonInputType.cpp |
@@ -34,6 +34,7 @@ |
#include "core/HTMLNames.h" |
#include "core/dom/Text.h" |
#include "core/dom/shadow/ShadowRoot.h" |
+#include "core/html/HTMLFormElement.h" |
#include "core/html/HTMLInputElement.h" |
#include "core/html/parser/HTMLParserIdioms.h" |
#include "core/layout/LayoutButton.h" |
@@ -82,4 +83,9 @@ void BaseButtonInputType::setValue(const String& sanitizedValue, bool, TextField |
element().setAttribute(valueAttr, AtomicString(sanitizedValue)); |
} |
+bool BaseButtonInputType::matchesDefaultPseudoClass() |
+{ |
tkent
2016/03/04 06:39:14
Please copy the comment in HTMLFormControlElement:
ramya.v
2016/03/04 10:22:40
Done.
|
+ return canBeSuccessfulSubmitButton() && element().form() && element().form()->defaultButton() == &element(); |
+} |
+ |
} // namespace blink |