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 302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
313 } | 313 } |
314 | 314 |
315 bool WindowManager::OnWmSetProperty( | 315 bool WindowManager::OnWmSetProperty( |
316 ui::Window* window, | 316 ui::Window* window, |
317 const std::string& name, | 317 const std::string& name, |
318 std::unique_ptr<std::vector<uint8_t>>* new_data) { | 318 std::unique_ptr<std::vector<uint8_t>>* new_data) { |
319 // TODO(sky): constrain this to set of keys we know about, and allowed values. | 319 // TODO(sky): constrain this to set of keys we know about, and allowed values. |
320 return name == ui::mojom::WindowManager::kShowState_Property || | 320 return name == ui::mojom::WindowManager::kShowState_Property || |
321 name == ui::mojom::WindowManager::kPreferredSize_Property || | 321 name == ui::mojom::WindowManager::kPreferredSize_Property || |
322 name == ui::mojom::WindowManager::kResizeBehavior_Property || | 322 name == ui::mojom::WindowManager::kResizeBehavior_Property || |
323 name == ui::mojom::WindowManager::kShelfIconResourceId_Property || | |
324 name == ui::mojom::WindowManager::kShelfItemType_Property || | 323 name == ui::mojom::WindowManager::kShelfItemType_Property || |
325 name == ui::mojom::WindowManager::kWindowAppIcon_Property || | 324 name == ui::mojom::WindowManager::kWindowAppIcon_Property || |
326 name == ui::mojom::WindowManager::kWindowTitle_Property; | 325 name == ui::mojom::WindowManager::kWindowTitle_Property; |
327 } | 326 } |
328 | 327 |
329 ui::Window* WindowManager::OnWmCreateTopLevelWindow( | 328 ui::Window* WindowManager::OnWmCreateTopLevelWindow( |
330 std::map<std::string, std::vector<uint8_t>>* properties) { | 329 std::map<std::string, std::vector<uint8_t>>* properties) { |
331 return NewTopLevelWindow(properties); | 330 return NewTopLevelWindow(properties); |
332 } | 331 } |
333 | 332 |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
392 const ui::Event& event) { | 391 const ui::Event& event) { |
393 auto iter = accelerator_handlers_.find(GetAcceleratorNamespaceId(id)); | 392 auto iter = accelerator_handlers_.find(GetAcceleratorNamespaceId(id)); |
394 if (iter == accelerator_handlers_.end()) | 393 if (iter == accelerator_handlers_.end()) |
395 return ui::mojom::EventResult::HANDLED; | 394 return ui::mojom::EventResult::HANDLED; |
396 | 395 |
397 return iter->second->OnAccelerator(id, event); | 396 return iter->second->OnAccelerator(id, event); |
398 } | 397 } |
399 | 398 |
400 } // namespace mus | 399 } // namespace mus |
401 } // namespace ash | 400 } // namespace ash |
OLD | NEW |