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

Unified Diff: third_party/WebKit/Source/core/dom/Node.cpp

Issue 2835483002: Add use counter for dispatching mouse events on disabled form controls. (Closed)
Patch Set: Created 3 years, 8 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/frame/UseCounter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/dom/Node.cpp
diff --git a/third_party/WebKit/Source/core/dom/Node.cpp b/third_party/WebKit/Source/core/dom/Node.cpp
index a61464b7c7b714a55b57fa53ef6c8f894772ec11..752e30a519db1f3157c6fe54de31537f77c17df0 100644
--- a/third_party/WebKit/Source/core/dom/Node.cpp
+++ b/third_party/WebKit/Source/core/dom/Node.cpp
@@ -88,6 +88,7 @@
#include "core/frame/FrameView.h"
#include "core/frame/LocalDOMWindow.h"
#include "core/frame/LocalFrame.h"
+#include "core/frame/UseCounter.h"
#include "core/html/HTMLDialogElement.h"
#include "core/html/HTMLFrameOwnerElement.h"
#include "core/html/HTMLSlotElement.h"
@@ -2098,8 +2099,11 @@ void Node::HandleLocalEvents(Event& event) {
if (!HasEventTargetData())
return;
- if (IsDisabledFormControl(this) && event.IsMouseEvent())
+ if (IsDisabledFormControl(this) && event.IsMouseEvent()) {
+ UseCounter::Count(GetDocument(),
+ UseCounter::kDispatchMouseEventOnDisabledFormControl);
return;
+ }
FireEventListeners(&event);
}
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/frame/UseCounter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698