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

Side by Side Diff: third_party/WebKit/Source/core/dom/Node.h

Issue 1479923002: Enumerate the return value of dispatchEvent so it is clear. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master_passive_uma_add
Patch Set: Add back the EventDispatchResult enum Created 4 years, 10 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 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-2011, 2014 Apple Inc. All rights reserved. 5 * Copyright (C) 2004-2011, 2014 Apple Inc. All rights reserved.
6 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 6 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 623 matching lines...) Expand 10 before | Expand all | Expand 10 after
634 // Handlers to do/undo actions on the target node before an event is dispatc hed to it and after the event 634 // Handlers to do/undo actions on the target node before an event is dispatc hed to it and after the event
635 // has been dispatched. The data pointer is handed back by the preDispatch and passed to postDispatch. 635 // has been dispatched. The data pointer is handed back by the preDispatch and passed to postDispatch.
636 virtual void* preDispatchEventHandler(Event*) { return nullptr; } 636 virtual void* preDispatchEventHandler(Event*) { return nullptr; }
637 virtual void postDispatchEventHandler(Event*, void* /*dataFromPreDispatch*/) { } 637 virtual void postDispatchEventHandler(Event*, void* /*dataFromPreDispatch*/) { }
638 638
639 void dispatchScopedEvent(PassRefPtrWillBeRawPtr<Event>); 639 void dispatchScopedEvent(PassRefPtrWillBeRawPtr<Event>);
640 640
641 virtual void handleLocalEvents(Event&); 641 virtual void handleLocalEvents(Event&);
642 642
643 void dispatchSubtreeModifiedEvent(); 643 void dispatchSubtreeModifiedEvent();
644 bool dispatchDOMActivateEvent(int detail, PassRefPtrWillBeRawPtr<Event> unde rlyingEvent); 644 EventTarget::DispatchEventResult dispatchDOMActivateEvent(int detail, PassRe fPtrWillBeRawPtr<Event> underlyingEvent);
645 645
646 bool dispatchMouseEvent(const PlatformMouseEvent&, const AtomicString& event Type, int clickCount = 0, Node* relatedTarget = nullptr); 646 EventTarget::DispatchEventResult dispatchMouseEvent(const PlatformMouseEvent &, const AtomicString& eventType, int clickCount = 0, Node* relatedTarget = null ptr);
647 647
648 void dispatchSimulatedClick(Event* underlyingEvent, SimulatedClickMouseEvent Options = SendNoEvents, SimulatedClickCreationScope = SimulatedClickCreationScop e::FromUserAgent); 648 void dispatchSimulatedClick(Event* underlyingEvent, SimulatedClickMouseEvent Options = SendNoEvents, SimulatedClickCreationScope = SimulatedClickCreationScop e::FromUserAgent);
649 649
650 void dispatchInputEvent(); 650 void dispatchInputEvent();
651 651
652 // Perform the default action for an event. 652 // Perform the default action for an event.
653 virtual void defaultEventHandler(Event*); 653 virtual void defaultEventHandler(Event*);
654 virtual void willCallDefaultEventHandler(const Event&); 654 virtual void willCallDefaultEventHandler(const Event&);
655 655
656 EventTargetData* eventTargetData() override; 656 EventTargetData* eventTargetData() override;
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
754 CreateInsertionPoint = CreateHTMLElement | IsInsertionPointFlag, 754 CreateInsertionPoint = CreateHTMLElement | IsInsertionPointFlag,
755 CreateEditingText = CreateText | HasNameOrIsEditingTextFlag, 755 CreateEditingText = CreateText | HasNameOrIsEditingTextFlag,
756 }; 756 };
757 757
758 Node(TreeScope*, ConstructionType); 758 Node(TreeScope*, ConstructionType);
759 759
760 virtual void didMoveToNewDocument(Document& oldDocument); 760 virtual void didMoveToNewDocument(Document& oldDocument);
761 761
762 bool addEventListenerInternal(const AtomicString& eventType, PassRefPtrWillB eRawPtr<EventListener>, const EventListenerOptions&) override; 762 bool addEventListenerInternal(const AtomicString& eventType, PassRefPtrWillB eRawPtr<EventListener>, const EventListenerOptions&) override;
763 bool removeEventListenerInternal(const AtomicString& eventType, PassRefPtrWi llBeRawPtr<EventListener>, const EventListenerOptions&) override; 763 bool removeEventListenerInternal(const AtomicString& eventType, PassRefPtrWi llBeRawPtr<EventListener>, const EventListenerOptions&) override;
764 bool dispatchEventInternal(PassRefPtrWillBeRawPtr<Event>) override; 764 EventTarget::DispatchEventResult dispatchEventInternal(PassRefPtrWillBeRawPt r<Event>) override;
765 765
766 static void reattachWhitespaceSiblingsIfNeeded(Text* start); 766 static void reattachWhitespaceSiblingsIfNeeded(Text* start);
767 767
768 #if !ENABLE(OILPAN) 768 #if !ENABLE(OILPAN)
769 void willBeDeletedFromDocument(); 769 void willBeDeletedFromDocument();
770 #endif 770 #endif
771 771
772 bool hasRareData() const { return getFlag(HasRareDataFlag); } 772 bool hasRareData() const { return getFlag(HasRareDataFlag); }
773 773
774 NodeRareData* rareData() const; 774 NodeRareData* rareData() const;
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
928 } // namespace blink 928 } // namespace blink
929 929
930 #ifndef NDEBUG 930 #ifndef NDEBUG
931 // Outside the WebCore namespace for ease of invocation from gdb. 931 // Outside the WebCore namespace for ease of invocation from gdb.
932 void showNode(const blink::Node*); 932 void showNode(const blink::Node*);
933 void showTree(const blink::Node*); 933 void showTree(const blink::Node*);
934 void showNodePath(const blink::Node*); 934 void showNodePath(const blink::Node*);
935 #endif 935 #endif
936 936
937 #endif // Node_h 937 #endif // Node_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698