| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 SERVICES_UI_WS_DRAG_CONTROLLER_H_ | 5 #ifndef SERVICES_UI_WS_DRAG_CONTROLLER_H_ |
| 6 #define SERVICES_UI_WS_DRAG_CONTROLLER_H_ | 6 #define SERVICES_UI_WS_DRAG_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <set> | 9 #include <set> |
| 10 | 10 |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 86 // that the drag source allows. | 86 // that the drag source allows. |
| 87 ui::mojom::Cursor CursorForEffectBitmask(DropEffectBitmask bitmask); | 87 ui::mojom::Cursor CursorForEffectBitmask(DropEffectBitmask bitmask); |
| 88 | 88 |
| 89 // Ensure that |window| has an entry in |window_state_| and that we're an | 89 // Ensure that |window| has an entry in |window_state_| and that we're an |
| 90 // observer. | 90 // observer. |
| 91 void EnsureWindowObserved(ServerWindow* window); | 91 void EnsureWindowObserved(ServerWindow* window); |
| 92 | 92 |
| 93 void QueueOperation(ServerWindow* window, | 93 void QueueOperation(ServerWindow* window, |
| 94 OperationType type, | 94 OperationType type, |
| 95 uint32_t event_flags, | 95 uint32_t event_flags, |
| 96 gfx::Point screen_position); | 96 const gfx::Point& screen_position); |
| 97 void DispatchOperation(ServerWindow* window, WindowState* state); | 97 void DispatchOperation(ServerWindow* window, WindowState* state); |
| 98 void OnRespondToOperation(ServerWindow* window); | 98 void OnRespondToOperation(ServerWindow* window); |
| 99 | 99 |
| 100 // Callback methods. | 100 // Callback methods. |
| 101 void OnDragStatusCompleted(const WindowId& id, DropEffectBitmask bitmask); | 101 void OnDragStatusCompleted(const WindowId& id, DropEffectBitmask bitmask); |
| 102 void OnDragDropCompleted(const WindowId& id, DropEffect action); | 102 void OnDragDropCompleted(const WindowId& id, DropEffect action); |
| 103 | 103 |
| 104 // ServerWindowObserver: | 104 // ServerWindowObserver: |
| 105 void OnWindowDestroying(ServerWindow* window) override; | 105 void OnWindowDestroying(ServerWindow* window) override; |
| 106 | 106 |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 144 | 144 |
| 145 base::WeakPtrFactory<DragController> weak_factory_; | 145 base::WeakPtrFactory<DragController> weak_factory_; |
| 146 | 146 |
| 147 DISALLOW_COPY_AND_ASSIGN(DragController); | 147 DISALLOW_COPY_AND_ASSIGN(DragController); |
| 148 }; | 148 }; |
| 149 | 149 |
| 150 } // namespace ws | 150 } // namespace ws |
| 151 } // namespace ui | 151 } // namespace ui |
| 152 | 152 |
| 153 #endif // SERVICES_UI_WS_DRAG_CONTROLLER_H_ | 153 #endif // SERVICES_UI_WS_DRAG_CONTROLLER_H_ |
| OLD | NEW |