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

Unified Diff: third_party/WebKit/Source/core/events/EventTarget.cpp

Issue 2163893003: Start sending auxclick instead of click for non-primary buttons (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Another rebase Created 4 years, 4 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: third_party/WebKit/Source/core/events/EventTarget.cpp
diff --git a/third_party/WebKit/Source/core/events/EventTarget.cpp b/third_party/WebKit/Source/core/events/EventTarget.cpp
index 19d5091f15ebdd4558136670d22ba78525c43cb5..b6196b5a5759518ddaad490125bcb550e619f540 100644
--- a/third_party/WebKit/Source/core/events/EventTarget.cpp
+++ b/third_party/WebKit/Source/core/events/EventTarget.cpp
@@ -295,7 +295,11 @@ bool EventTarget::addEventListenerInternal(const AtomicString& eventType, EventL
void EventTarget::addedEventListener(const AtomicString& eventType, RegisteredEventListener& registeredListener)
{
- if (EventUtil::isPointerEventType(eventType)) {
+ if (eventType == EventTypeNames::auxclick) {
+ if (LocalDOMWindow* executingWindow = this->executingWindow()) {
+ UseCounter::count(executingWindow->document(), UseCounter::AuxclickAddListenerCount);
+ }
+ } else if (EventUtil::isPointerEventType(eventType)) {
if (LocalDOMWindow* executingWindow = this->executingWindow()) {
UseCounter::count(executingWindow->document(), UseCounter::PointerEventAddListenerCount);
}
« no previous file with comments | « third_party/WebKit/Source/core/dom/GlobalEventHandlers.idl ('k') | third_party/WebKit/Source/core/events/EventTypeNames.in » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698