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

Side by Side Diff: ui/events/event_handler.h

Issue 24257011: Revert "Revert 224496 "Move ui/base/latency_info* to ui/events"" (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix gyp bustage Created 7 years, 2 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
« no previous file with comments | « ui/events/event_dispatcher.h ('k') | ui/events/event_target.h » ('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 #ifndef UI_EVENTS_EVENT_HANDLER_H_ 5 #ifndef UI_EVENTS_EVENT_HANDLER_H_
6 #define UI_EVENTS_EVENT_HANDLER_H_ 6 #define UI_EVENTS_EVENT_HANDLER_H_
7 7
8 #include <stack> 8 #include <stack>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/basictypes.h" 11 #include "base/basictypes.h"
12 #include "ui/base/ui_export.h"
13 #include "ui/events/event_constants.h" 12 #include "ui/events/event_constants.h"
13 #include "ui/events/events_export.h"
14 14
15 namespace ui { 15 namespace ui {
16 16
17 class CancelModeEvent; 17 class CancelModeEvent;
18 class Event; 18 class Event;
19 class EventDispatcher; 19 class EventDispatcher;
20 class EventTarget; 20 class EventTarget;
21 class GestureEvent; 21 class GestureEvent;
22 class KeyEvent; 22 class KeyEvent;
23 class MouseEvent; 23 class MouseEvent;
24 class ScrollEvent; 24 class ScrollEvent;
25 class TouchEvent; 25 class TouchEvent;
26 26
27 // Dispatches events to appropriate targets. The default implementations of 27 // Dispatches events to appropriate targets. The default implementations of
28 // all of the specific handlers (e.g. OnKeyEvent, OnMouseEvent) do nothing. 28 // all of the specific handlers (e.g. OnKeyEvent, OnMouseEvent) do nothing.
29 class UI_EXPORT EventHandler { 29 class EVENTS_EXPORT EventHandler {
30 public: 30 public:
31 EventHandler(); 31 EventHandler();
32 virtual ~EventHandler(); 32 virtual ~EventHandler();
33 33
34 // This is called for all events. The default implementation routes the event 34 // This is called for all events. The default implementation routes the event
35 // to one of the event-specific callbacks (OnKeyEvent, OnMouseEvent etc.). If 35 // to one of the event-specific callbacks (OnKeyEvent, OnMouseEvent etc.). If
36 // this is overridden, then normally, the override should chain into the 36 // this is overridden, then normally, the override should chain into the
37 // default implementation for un-handled events. 37 // default implementation for un-handled events.
38 virtual void OnEvent(Event* event); 38 virtual void OnEvent(Event* event);
39 39
(...skipping 17 matching lines...) Expand all
57 std::stack<EventDispatcher*> dispatchers_; 57 std::stack<EventDispatcher*> dispatchers_;
58 58
59 DISALLOW_COPY_AND_ASSIGN(EventHandler); 59 DISALLOW_COPY_AND_ASSIGN(EventHandler);
60 }; 60 };
61 61
62 typedef std::vector<EventHandler*> EventHandlerList; 62 typedef std::vector<EventHandler*> EventHandlerList;
63 63
64 } // namespace ui 64 } // namespace ui
65 65
66 #endif // UI_EVENTS_EVENT_HANDLER_H_ 66 #endif // UI_EVENTS_EVENT_HANDLER_H_
OLDNEW
« no previous file with comments | « ui/events/event_dispatcher.h ('k') | ui/events/event_target.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698