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

Unified Diff: ui/events/event_processor.cc

Issue 533323004: Remove RootView::DispatchGestureEvent() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: test added, member name changed Created 6 years, 3 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 | « ui/events/event_processor.h ('k') | ui/events/event_processor_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/events/event_processor.cc
diff --git a/ui/events/event_processor.cc b/ui/events/event_processor.cc
index 3806fbc03984e05c6d27876ac48e49b5f29f410a..25c8c3fae92ca2b74e723fce69ee2fe6792b6c49 100644
--- a/ui/events/event_processor.cc
+++ b/ui/events/event_processor.cc
@@ -27,8 +27,9 @@ EventDispatchDetails EventProcessor::OnEventFromSource(Event* event) {
}
EventTarget* target = targeter->FindTargetForEvent(root, event_to_dispatch);
+ EventDispatchDetails details;
while (target) {
- EventDispatchDetails details = DispatchEvent(target, event_to_dispatch);
+ details = DispatchEvent(target, event_to_dispatch);
if (!dispatch_original_event) {
if (event_to_dispatch->stopped_propagation())
@@ -37,19 +38,23 @@ EventDispatchDetails EventProcessor::OnEventFromSource(Event* event) {
event->SetHandled();
}
- if (details.dispatcher_destroyed ||
- details.target_destroyed ||
- event->handled()) {
+ if (details.dispatcher_destroyed)
return details;
- }
+
+ if (details.target_destroyed || event->handled())
+ break;
target = targeter->FindNextBestTarget(target, event_to_dispatch);
}
- return EventDispatchDetails();
+ OnEventProcessingFinished(event);
+ return details;
}
void EventProcessor::PrepareEventForDispatch(Event* event) {
}
+void EventProcessor::OnEventProcessingFinished(Event* event) {
+}
+
} // namespace ui
« no previous file with comments | « ui/events/event_processor.h ('k') | ui/events/event_processor_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698