Index: third_party/WebKit/Source/core/html/HTMLInputElement.cpp |
diff --git a/third_party/WebKit/Source/core/html/HTMLInputElement.cpp b/third_party/WebKit/Source/core/html/HTMLInputElement.cpp |
index 5b0c88c1637ab1d087f0011daee466c585d87bde..1a52b21e6db3ad6dc24f78a46ace39a749f65a1f 100644 |
--- a/third_party/WebKit/Source/core/html/HTMLInputElement.cpp |
+++ b/third_party/WebKit/Source/core/html/HTMLInputElement.cpp |
@@ -475,6 +475,7 @@ void HTMLInputElement::updateType() |
bool didStoreValue = m_inputType->storesValueSeparateFromAttribute(); |
bool didRespectHeightAndWidth = m_inputType->shouldRespectHeightAndWidthAttributes(); |
+ bool couldBeSuccessfulSubmitButton = canBeSuccessfulSubmitButton(); |
m_inputTypeView->destroyShadowSubtree(); |
lazyReattachIfAttached(); |
@@ -529,6 +530,8 @@ void HTMLInputElement::updateType() |
addToRadioButtonGroup(); |
setNeedsValidityCheck(); |
+ if ((couldBeSuccessfulSubmitButton || canBeSuccessfulSubmitButton()) && formOwner() && inDocument()) |
+ formOwner()->invalidateDefaultButtonStyle(); |
notifyFormStateChanged(); |
} |