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

Side by Side Diff: third_party/WebKit/Source/core/events/EventTarget.cpp

Issue 2379923002: Implement "appinstalled" event on Android. (Closed)
Patch Set: Blink style. Created 4 years 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. 5 * Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved.
6 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) 6 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org)
7 * (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org> 7 * (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org>
8 * 8 *
9 * Redistribution and use in source and binary forms, with or without 9 * Redistribution and use in source and binary forms, with or without
10 * modification, are permitted provided that the following conditions 10 * modification, are permitted provided that the following conditions
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after
298 } 298 }
299 299
300 void EventTarget::addedEventListener( 300 void EventTarget::addedEventListener(
301 const AtomicString& eventType, 301 const AtomicString& eventType,
302 RegisteredEventListener& registeredListener) { 302 RegisteredEventListener& registeredListener) {
303 if (eventType == EventTypeNames::auxclick) { 303 if (eventType == EventTypeNames::auxclick) {
304 if (LocalDOMWindow* executingWindow = this->executingWindow()) { 304 if (LocalDOMWindow* executingWindow = this->executingWindow()) {
305 UseCounter::count(executingWindow->document(), 305 UseCounter::count(executingWindow->document(),
306 UseCounter::AuxclickAddListenerCount); 306 UseCounter::AuxclickAddListenerCount);
307 } 307 }
308 } else if (eventType == EventTypeNames::appinstalled) {
309 if (LocalDOMWindow* executingWindow = this->executingWindow()) {
310 UseCounter::count(executingWindow->document(),
311 UseCounter::AppInstalledEventAddListener);
312 }
308 } else if (EventUtil::isPointerEventType(eventType)) { 313 } else if (EventUtil::isPointerEventType(eventType)) {
309 if (LocalDOMWindow* executingWindow = this->executingWindow()) { 314 if (LocalDOMWindow* executingWindow = this->executingWindow()) {
310 UseCounter::count(executingWindow->document(), 315 UseCounter::count(executingWindow->document(),
311 UseCounter::PointerEventAddListenerCount); 316 UseCounter::PointerEventAddListenerCount);
312 } 317 }
313 } else if (eventType == EventTypeNames::slotchange) { 318 } else if (eventType == EventTypeNames::slotchange) {
314 if (LocalDOMWindow* executingWindow = this->executingWindow()) { 319 if (LocalDOMWindow* executingWindow = this->executingWindow()) {
315 UseCounter::count(executingWindow->document(), 320 UseCounter::count(executingWindow->document(),
316 UseCounter::SlotChangeEventAddListener); 321 UseCounter::SlotChangeEventAddListener);
317 } 322 }
(...skipping 432 matching lines...) Expand 10 before | Expand all | Expand 10 after
750 // they have one less listener to invoke. 755 // they have one less listener to invoke.
751 if (d->firingEventIterators) { 756 if (d->firingEventIterators) {
752 for (const auto& iterator : *d->firingEventIterators) { 757 for (const auto& iterator : *d->firingEventIterators) {
753 iterator.iterator = 0; 758 iterator.iterator = 0;
754 iterator.end = 0; 759 iterator.end = 0;
755 } 760 }
756 } 761 }
757 } 762 }
758 763
759 } // namespace blink 764 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698