OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/mus/window_manager.h" | 5 #include "ash/mus/window_manager.h" |
6 | 6 |
7 #include <stdint.h> | 7 #include <stdint.h> |
8 | 8 |
9 #include <utility> | 9 #include <utility> |
10 | 10 |
(...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
213 shell_.reset(); | 213 shell_.reset(); |
214 shadow_controller_.reset(); | 214 shadow_controller_.reset(); |
215 | 215 |
216 FOR_EACH_OBSERVER(WindowManagerObserver, observers_, | 216 FOR_EACH_OBSERVER(WindowManagerObserver, observers_, |
217 OnWindowTreeClientDestroyed()); | 217 OnWindowTreeClientDestroyed()); |
218 | 218 |
219 window_tree_client_ = nullptr; | 219 window_tree_client_ = nullptr; |
220 window_manager_client_ = nullptr; | 220 window_manager_client_ = nullptr; |
221 } | 221 } |
222 | 222 |
223 void WindowManager::OnEventObserved(const ui::Event& event, | 223 void WindowManager::OnPointerEventObserved(const ui::PointerEvent& event, |
224 ui::Window* target) { | 224 ui::Window* target) { |
225 // Does not use EventObservers. | 225 // Does not use PointerWatchers. |
226 } | 226 } |
227 | 227 |
228 void WindowManager::SetWindowManagerClient(ui::WindowManagerClient* client) { | 228 void WindowManager::SetWindowManagerClient(ui::WindowManagerClient* client) { |
229 window_manager_client_ = client; | 229 window_manager_client_ = client; |
230 } | 230 } |
231 | 231 |
232 bool WindowManager::OnWmSetBounds(ui::Window* window, gfx::Rect* bounds) { | 232 bool WindowManager::OnWmSetBounds(ui::Window* window, gfx::Rect* bounds) { |
233 // TODO(sky): this indirectly sets bounds, which is against what | 233 // TODO(sky): this indirectly sets bounds, which is against what |
234 // OnWmSetBounds() recommends doing. Remove that restriction, or fix this. | 234 // OnWmSetBounds() recommends doing. Remove that restriction, or fix this. |
235 WmWindowMus::Get(window)->SetBounds(*bounds); | 235 WmWindowMus::Get(window)->SetBounds(*bounds); |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
298 const ui::Event& event) { | 298 const ui::Event& event) { |
299 auto iter = accelerator_handlers_.find(GetAcceleratorNamespaceId(id)); | 299 auto iter = accelerator_handlers_.find(GetAcceleratorNamespaceId(id)); |
300 if (iter == accelerator_handlers_.end()) | 300 if (iter == accelerator_handlers_.end()) |
301 return ui::mojom::EventResult::HANDLED; | 301 return ui::mojom::EventResult::HANDLED; |
302 | 302 |
303 return iter->second->OnAccelerator(id, event); | 303 return iter->second->OnAccelerator(id, event); |
304 } | 304 } |
305 | 305 |
306 } // namespace mus | 306 } // namespace mus |
307 } // namespace ash | 307 } // namespace ash |
OLD | NEW |