| Index: ash/common/wm_shell.cc
|
| diff --git a/ash/common/wm_shell.cc b/ash/common/wm_shell.cc
|
| index 2161121c8fda5a8f5b2b6ad92e22b747eed071e3..def0eb526616efd17fdd96e1cf4fc8a8aa4c4305 100644
|
| --- a/ash/common/wm_shell.cc
|
| +++ b/ash/common/wm_shell.cc
|
| @@ -4,6 +4,9 @@
|
|
|
| #include "ash/common/wm_shell.h"
|
|
|
| +#include "ash/common/system/tray/system_tray_delegate.h"
|
| +#include "base/logging.h"
|
| +
|
| namespace ash {
|
|
|
| // static
|
| @@ -19,4 +22,22 @@ WmShell* WmShell::Get() {
|
| return instance_;
|
| }
|
|
|
| +WmShell::WmShell() {}
|
| +
|
| +WmShell::~WmShell() {}
|
| +
|
| +void WmShell::SetSystemTrayDelegate(
|
| + std::unique_ptr<SystemTrayDelegate> delegate) {
|
| + if (delegate) {
|
| + DCHECK(!system_tray_delegate_);
|
| + // TODO(jamescook): Create via ShellDelegate once it moves to //ash/common.
|
| + system_tray_delegate_ = std::move(delegate);
|
| + system_tray_delegate_->Initialize();
|
| + } else {
|
| + DCHECK(system_tray_delegate_);
|
| + system_tray_delegate_->Shutdown();
|
| + system_tray_delegate_.reset();
|
| + }
|
| +}
|
| +
|
| } // namespace ash
|
|
|