| Index: mash/wm/root_window_controller.cc
|
| diff --git a/mash/wm/root_window_controller.cc b/mash/wm/root_window_controller.cc
|
| index 914d9111d6ac097c8a12a7612ee84b3eae68cc28..2d2d6c61605708418e99f70728e7f3272d3770f5 100644
|
| --- a/mash/wm/root_window_controller.cc
|
| +++ b/mash/wm/root_window_controller.cc
|
| @@ -87,6 +87,18 @@ bool RootWindowController::WindowIsContainer(const mus::Window* window) const {
|
| return window && window->parent() == root_;
|
| }
|
|
|
| +void RootWindowController::OnAccelerator(uint32_t id,
|
| + mus::mojom::EventPtr event) {
|
| + switch (id) {
|
| + case kWindowSwitchAccelerator:
|
| + window_tree_host_->ActivateNextWindow();
|
| + break;
|
| + default:
|
| + app_->OnAccelerator(id, std::move(event));
|
| + break;
|
| + }
|
| +}
|
| +
|
| RootWindowController::RootWindowController(WindowManagerApplication* app)
|
| : app_(app), root_(nullptr), window_count_(0), host_client_binding_(this) {
|
| window_manager_.reset(new WindowManager);
|
| @@ -95,25 +107,13 @@ RootWindowController::RootWindowController(WindowManagerApplication* app)
|
| RootWindowController::~RootWindowController() {}
|
|
|
| void RootWindowController::AddAccelerators() {
|
| - window_tree_host_->AddAccelerator(
|
| + window_manager_->window_manager_client()->AddAccelerator(
|
| kWindowSwitchAccelerator,
|
| mus::CreateKeyMatcher(mus::mojom::KeyboardCode::TAB,
|
| mus::mojom::kEventFlagControlDown),
|
| base::Bind(&AssertTrue));
|
| }
|
|
|
| -void RootWindowController::OnAccelerator(uint32_t id,
|
| - mus::mojom::EventPtr event) {
|
| - switch (id) {
|
| - case kWindowSwitchAccelerator:
|
| - window_tree_host_->ActivateNextWindow();
|
| - break;
|
| - default:
|
| - app_->OnAccelerator(id, std::move(event));
|
| - break;
|
| - }
|
| -}
|
| -
|
| void RootWindowController::OnEmbed(mus::Window* root) {
|
| root_ = root;
|
| root_->AddObserver(this);
|
|
|