| 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 "ash/mus/bridge/wm_shell_mus.h" | 5 #include "ash/mus/bridge/wm_shell_mus.h" |
| 6 | 6 |
| 7 #include "ash/common/default_accessibility_delegate.h" | 7 #include "ash/common/default_accessibility_delegate.h" |
| 8 #include "ash/common/display/display_info.h" | 8 #include "ash/common/display/display_info.h" |
| 9 #include "ash/common/session/session_state_delegate.h" | 9 #include "ash/common/session/session_state_delegate.h" |
| 10 #include "ash/common/shell_observer.h" | 10 #include "ash/common/shell_observer.h" |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 97 WmShell::Set(this); | 97 WmShell::Set(this); |
| 98 | 98 |
| 99 wm_shell_common_.reset(new WmShellCommon); | 99 wm_shell_common_.reset(new WmShellCommon); |
| 100 wm_shell_common_->CreateMruWindowTracker(); | 100 wm_shell_common_->CreateMruWindowTracker(); |
| 101 | 101 |
| 102 accessibility_delegate_.reset(new DefaultAccessibilityDelegate); | 102 accessibility_delegate_.reset(new DefaultAccessibilityDelegate); |
| 103 SetSystemTrayDelegate(base::WrapUnique(new DefaultSystemTrayDelegate)); | 103 SetSystemTrayDelegate(base::WrapUnique(new DefaultSystemTrayDelegate)); |
| 104 } | 104 } |
| 105 | 105 |
| 106 WmShellMus::~WmShellMus() { | 106 WmShellMus::~WmShellMus() { |
| 107 SetSystemTrayDelegate(nullptr); | 107 DeleteSystemTrayDelegate(); |
| 108 DeleteWindowSelectorController(); | 108 DeleteWindowSelectorController(); |
| 109 wm_shell_common_->DeleteMruWindowTracker(); | 109 wm_shell_common_->DeleteMruWindowTracker(); |
| 110 RemoveClientObserver(); | 110 RemoveClientObserver(); |
| 111 WmShell::Set(nullptr); | 111 WmShell::Set(nullptr); |
| 112 } | 112 } |
| 113 | 113 |
| 114 // static | 114 // static |
| 115 WmShellMus* WmShellMus::Get() { | 115 WmShellMus* WmShellMus::Get() { |
| 116 return static_cast<WmShellMus*>(WmShell::Get()); | 116 return static_cast<WmShellMus*>(WmShell::Get()); |
| 117 } | 117 } |
| (...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 313 OnWindowActivated(gained_active, lost_active)); | 313 OnWindowActivated(gained_active, lost_active)); |
| 314 } | 314 } |
| 315 | 315 |
| 316 void WmShellMus::OnWillDestroyClient(::mus::WindowTreeClient* client) { | 316 void WmShellMus::OnWillDestroyClient(::mus::WindowTreeClient* client) { |
| 317 DCHECK_EQ(client, client_); | 317 DCHECK_EQ(client, client_); |
| 318 RemoveClientObserver(); | 318 RemoveClientObserver(); |
| 319 } | 319 } |
| 320 | 320 |
| 321 } // namespace mus | 321 } // namespace mus |
| 322 } // namespace ash | 322 } // namespace ash |
| OLD | NEW |