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 #include "services/ui/ws/window_manager_state.h" | 5 #include "services/ui/ws/window_manager_state.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/memory/weak_ptr.h" | 9 #include "base/memory/weak_ptr.h" |
10 #include "services/shell/public/interfaces/connector.mojom.h" | 10 #include "services/shell/public/interfaces/connector.mojom.h" |
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
147 | 147 |
148 void WindowManagerState::ReleaseCaptureBlockedByModalWindow( | 148 void WindowManagerState::ReleaseCaptureBlockedByModalWindow( |
149 const ServerWindow* modal_window) { | 149 const ServerWindow* modal_window) { |
150 event_dispatcher_.ReleaseCaptureBlockedByModalWindow(modal_window); | 150 event_dispatcher_.ReleaseCaptureBlockedByModalWindow(modal_window); |
151 } | 151 } |
152 | 152 |
153 void WindowManagerState::ReleaseCaptureBlockedByAnyModalWindow() { | 153 void WindowManagerState::ReleaseCaptureBlockedByAnyModalWindow() { |
154 event_dispatcher_.ReleaseCaptureBlockedByAnyModalWindow(); | 154 event_dispatcher_.ReleaseCaptureBlockedByAnyModalWindow(); |
155 } | 155 } |
156 | 156 |
| 157 void WindowManagerState::SetDragDropSourceWindow( |
| 158 CurrentDragOperationSource* drag_source, |
| 159 ServerWindow* window, |
| 160 mojo::Map<mojo::String, mojo::Array<uint8_t>> drag_data, |
| 161 uint32_t drag_operation) { |
| 162 event_dispatcher_.SetDragDropSourceWindow( |
| 163 drag_source, window, std::move(drag_data), drag_operation); |
| 164 } |
| 165 |
| 166 void WindowManagerState::EndDragDrop() { |
| 167 event_dispatcher_.EndDragDrop(); |
| 168 } |
| 169 |
157 void WindowManagerState::AddSystemModalWindow(ServerWindow* window) { | 170 void WindowManagerState::AddSystemModalWindow(ServerWindow* window) { |
158 DCHECK(!window->transient_parent()); | 171 DCHECK(!window->transient_parent()); |
159 event_dispatcher_.AddSystemModalWindow(window); | 172 event_dispatcher_.AddSystemModalWindow(window); |
160 } | 173 } |
161 | 174 |
162 const UserId& WindowManagerState::user_id() const { | 175 const UserId& WindowManagerState::user_id() const { |
163 return window_tree_->user_id(); | 176 return window_tree_->user_id(); |
164 } | 177 } |
165 | 178 |
166 void WindowManagerState::OnWillDestroyTree(WindowTree* tree) { | 179 void WindowManagerState::OnWillDestroyTree(WindowTree* tree) { |
(...skipping 394 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
561 return display_root->root(); | 574 return display_root->root(); |
562 } | 575 } |
563 | 576 |
564 void WindowManagerState::OnEventTargetNotFound(const ui::Event& event) { | 577 void WindowManagerState::OnEventTargetNotFound(const ui::Event& event) { |
565 window_server()->SendToPointerWatchers(event, user_id(), nullptr, /* window */ | 578 window_server()->SendToPointerWatchers(event, user_id(), nullptr, /* window */ |
566 nullptr /* ignore_tree */); | 579 nullptr /* ignore_tree */); |
567 } | 580 } |
568 | 581 |
569 } // namespace ws | 582 } // namespace ws |
570 } // namespace ui | 583 } // namespace ui |
OLD | NEW |