OLD | NEW |
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 "ash/wm/gestures/shelf_gesture_handler.h" | 5 #include "ash/wm/gestures/shelf_gesture_handler.h" |
6 | 6 |
7 #include "ash/root_window_controller.h" | 7 #include "ash/root_window_controller.h" |
8 #include "ash/session_state_delegate.h" | 8 #include "ash/session_state_delegate.h" |
9 #include "ash/shelf/shelf_layout_manager.h" | 9 #include "ash/shelf/shelf_layout_manager.h" |
10 #include "ash/shelf/shelf_types.h" | 10 #include "ash/shelf/shelf_types.h" |
11 #include "ash/shelf/shelf_widget.h" | 11 #include "ash/shelf/shelf_widget.h" |
12 #include "ash/shell.h" | 12 #include "ash/shell.h" |
13 #include "ash/system/status_area_widget.h" | 13 #include "ash/system/status_area_widget.h" |
14 #include "ash/wm/gestures/tray_gesture_handler.h" | 14 #include "ash/wm/gestures/tray_gesture_handler.h" |
15 #include "ash/wm/window_state.h" | 15 #include "ash/wm/window_state.h" |
16 #include "ash/wm/window_util.h" | 16 #include "ash/wm/window_util.h" |
17 #include "ui/aura/window.h" | 17 #include "ui/aura/window.h" |
18 #include "ui/compositor/layer.h" | 18 #include "ui/compositor/layer.h" |
19 #include "ui/compositor/scoped_layer_animation_settings.h" | 19 #include "ui/compositor/scoped_layer_animation_settings.h" |
20 #include "ui/gfx/transform.h" | 20 #include "ui/gfx/transform.h" |
21 #include "ui/views/widget/widget.h" | 21 #include "ui/views/widget/widget.h" |
22 | 22 |
23 namespace ash { | 23 namespace ash { |
24 namespace internal { | |
25 | 24 |
26 ShelfGestureHandler::ShelfGestureHandler() | 25 ShelfGestureHandler::ShelfGestureHandler() |
27 : drag_in_progress_(false) { | 26 : drag_in_progress_(false) { |
28 } | 27 } |
29 | 28 |
30 ShelfGestureHandler::~ShelfGestureHandler() { | 29 ShelfGestureHandler::~ShelfGestureHandler() { |
31 } | 30 } |
32 | 31 |
33 bool ShelfGestureHandler::ProcessGestureEvent(const ui::GestureEvent& event) { | 32 bool ShelfGestureHandler::ProcessGestureEvent(const ui::GestureEvent& event) { |
34 Shell* shell = Shell::GetInstance(); | 33 Shell* shell = Shell::GetInstance(); |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
86 | 85 |
87 shelf->CompleteGestureDrag(event); | 86 shelf->CompleteGestureDrag(event); |
88 return true; | 87 return true; |
89 } | 88 } |
90 | 89 |
91 // Unexpected event. Reset the state and let the event fall through. | 90 // Unexpected event. Reset the state and let the event fall through. |
92 shelf->CancelGestureDrag(); | 91 shelf->CancelGestureDrag(); |
93 return false; | 92 return false; |
94 } | 93 } |
95 | 94 |
96 } // namespace internal | |
97 } // namespace ash | 95 } // namespace ash |
OLD | NEW |