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

Side by Side Diff: ui/base/events/event_dispatcher.cc

Issue 10916210: events: Inlcude the event-phase and event-result in Event. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ui/base/events/event_dispatcher.h ('k') | ui/base/events/event_dispatcher_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/base/events/event_dispatcher.h" 5 #include "ui/base/events/event_dispatcher.h"
6 6
7 namespace ui { 7 namespace ui {
8 8
9 EventDispatcher::EventDispatcher() { 9 EventDispatcher::EventDispatcher() {
10 } 10 }
(...skipping 26 matching lines...) Expand all
37 return status == ui::TOUCH_STATUS_UNKNOWN ? ER_UNHANDLED : 37 return status == ui::TOUCH_STATUS_UNKNOWN ? ER_UNHANDLED :
38 status == ui::TOUCH_STATUS_QUEUED_END ? ER_CONSUMED : 38 status == ui::TOUCH_STATUS_QUEUED_END ? ER_CONSUMED :
39 ER_HANDLED; 39 ER_HANDLED;
40 } 40 }
41 41
42 EventResult EventDispatcher::DispatchEventToSingleHandler(EventHandler* handler, 42 EventResult EventDispatcher::DispatchEventToSingleHandler(EventHandler* handler,
43 GestureEvent* event) { 43 GestureEvent* event) {
44 return handler->OnGestureEvent(event); 44 return handler->OnGestureEvent(event);
45 } 45 }
46 46
47 ////////////////////////////////////////////////////////////////////////////////
48 // EventDispatcher::ScopedDispatchHelper
49
50 EventDispatcher::ScopedDispatchHelper::ScopedDispatchHelper(Event* event)
51 : Event::DispatcherApi(event) {
52 }
53
54 EventDispatcher::ScopedDispatchHelper::~ScopedDispatchHelper() {
55 set_phase(EP_POSTDISPATCH);
56 }
57
47 } // namespace ui 58 } // namespace ui
OLDNEW
« no previous file with comments | « ui/base/events/event_dispatcher.h ('k') | ui/base/events/event_dispatcher_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698