Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1010)

Unified Diff: Source/core/html/HTMLFormControlElement.h

Issue 658063002: Fix the issue where checking a form for :valid/:invalid would trigger invalid events for its elemen… (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/html/HTMLFormControlElement.h
diff --git a/Source/core/html/HTMLFormControlElement.h b/Source/core/html/HTMLFormControlElement.h
index 4904ed4277696ea1cf8d3a5303831c933a472a73..adbf2ff092bc0d13e6616c6edcecadabc26754fa 100644
--- a/Source/core/html/HTMLFormControlElement.h
+++ b/Source/core/html/HTMLFormControlElement.h
@@ -85,11 +85,10 @@ public:
virtual void setActivatedSubmit(bool) { }
virtual bool willValidate() const override;
- virtual bool matchesValidityPseudoClasses() const override;
void updateVisibleValidationMessage();
void hideVisibleValidationMessage();
- bool checkValidity(WillBeHeapVector<RefPtrWillBeMember<FormAssociatedElement> >* unhandledInvalidControls = 0);
+ bool checkValidity(WillBeHeapVector<RefPtrWillBeMember<FormAssociatedElement> >* unhandledInvalidControls = 0, bool fireInvalidEvent = true);
// This must be called when a validation constraint or control value is changed.
void setNeedsValidityCheck();
virtual void setCustomValidity(const String&) override final;
@@ -157,6 +156,7 @@ private:
virtual bool isDefaultButtonForForm() const override final;
virtual bool isValidElement() override final;
+ virtual bool matchesValidityPseudoClasses() const override final;
void updateAncestorDisabledState() const;
bool isValidationMessageVisible() const;

Powered by Google App Engine
This is Rietveld 408576698