OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_AURA_WINDOW_EVENT_DISPATCHER_H_ | 5 #ifndef UI_AURA_WINDOW_EVENT_DISPATCHER_H_ |
6 #define UI_AURA_WINDOW_EVENT_DISPATCHER_H_ | 6 #define UI_AURA_WINDOW_EVENT_DISPATCHER_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 27 matching lines...) Expand all Loading... |
38 class GestureEvent; | 38 class GestureEvent; |
39 class GestureRecognizer; | 39 class GestureRecognizer; |
40 class KeyEvent; | 40 class KeyEvent; |
41 class MouseEvent; | 41 class MouseEvent; |
42 class ScrollEvent; | 42 class ScrollEvent; |
43 class TouchEvent; | 43 class TouchEvent; |
44 } | 44 } |
45 | 45 |
46 namespace aura { | 46 namespace aura { |
47 class TestScreen; | 47 class TestScreen; |
| 48 class WindowEventDispatcherDelegate; |
48 class WindowTargeter; | 49 class WindowTargeter; |
49 class WindowTreeHost; | 50 class WindowTreeHost; |
50 | 51 |
51 namespace test { | 52 namespace test { |
52 class WindowEventDispatcherTestApi; | 53 class WindowEventDispatcherTestApi; |
53 } | 54 } |
54 | 55 |
55 // WindowEventDispatcher orchestrates event dispatch within a window tree | 56 // WindowEventDispatcher orchestrates event dispatch within a window tree |
56 // owned by WindowTreeHost. WTH also owns the WED. | 57 // owned by WindowTreeHost. WTH also owns the WED. |
57 // TODO(beng): In progress, remove functionality not directly related to | 58 // TODO(beng): In progress, remove functionality not directly related to |
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
265 // Allowing for reposting of events. Used when exiting context menus. | 266 // Allowing for reposting of events. Used when exiting context menus. |
266 std::unique_ptr<ui::LocatedEvent> held_repostable_event_; | 267 std::unique_ptr<ui::LocatedEvent> held_repostable_event_; |
267 | 268 |
268 // Set when dispatching a held event. | 269 // Set when dispatching a held event. |
269 ui::LocatedEvent* dispatching_held_event_; | 270 ui::LocatedEvent* dispatching_held_event_; |
270 | 271 |
271 ScopedObserver<aura::Window, aura::WindowObserver> observer_manager_; | 272 ScopedObserver<aura::Window, aura::WindowObserver> observer_manager_; |
272 | 273 |
273 bool transform_events_; | 274 bool transform_events_; |
274 | 275 |
| 276 std::unique_ptr<WindowEventDispatcherDelegate> delegate_; |
| 277 |
275 // Used to schedule reposting an event. | 278 // Used to schedule reposting an event. |
276 base::WeakPtrFactory<WindowEventDispatcher> repost_event_factory_; | 279 base::WeakPtrFactory<WindowEventDispatcher> repost_event_factory_; |
277 | 280 |
278 // Used to schedule DispatchHeldEvents() when |move_hold_count_| goes to 0. | 281 // Used to schedule DispatchHeldEvents() when |move_hold_count_| goes to 0. |
279 base::WeakPtrFactory<WindowEventDispatcher> held_event_factory_; | 282 base::WeakPtrFactory<WindowEventDispatcher> held_event_factory_; |
280 | 283 |
281 DISALLOW_COPY_AND_ASSIGN(WindowEventDispatcher); | 284 DISALLOW_COPY_AND_ASSIGN(WindowEventDispatcher); |
282 }; | 285 }; |
283 | 286 |
284 } // namespace aura | 287 } // namespace aura |
285 | 288 |
286 #endif // UI_AURA_WINDOW_EVENT_DISPATCHER_H_ | 289 #endif // UI_AURA_WINDOW_EVENT_DISPATCHER_H_ |
OLD | NEW |