Chromium Code Reviews| Index: ash/mus/window_manager_application.cc |
| diff --git a/ash/mus/window_manager_application.cc b/ash/mus/window_manager_application.cc |
| index f8b18788b7cc885ff0e29e6649ef433b924f6c42..de4bf1290e5ff036c8bde4093631e7cc571c965b 100644 |
| --- a/ash/mus/window_manager_application.cc |
| +++ b/ash/mus/window_manager_application.cc |
| @@ -23,11 +23,19 @@ |
| #include "ui/events/event.h" |
| #include "ui/views/mus/aura_init.h" |
| +#if defined(OS_CHROMEOS) |
| +#include "chromeos/dbus/dbus_thread_manager.h" |
| +#endif |
| + |
| namespace ash { |
| namespace mus { |
| WindowManagerApplication::WindowManagerApplication() |
| - : connector_(nullptr), screenlock_state_listener_binding_(this) {} |
| + : connector_(nullptr), screenlock_state_listener_binding_(this) { |
| +#if defined(OS_CHROMEOS) |
| + chromeos::DBusThreadManager::Initialize(); |
|
James Cook
2016/07/01 23:17:36
I put this here instead of in WMA::Initialize() be
|
| +#endif |
| +} |
| WindowManagerApplication::~WindowManagerApplication() { |
| // AcceleratorRegistrarImpl removes an observer in its destructor. Destroy |
| @@ -40,6 +48,10 @@ WindowManagerApplication::~WindowManagerApplication() { |
| // Destroy the WindowManager while still valid. This way we ensure |
| // OnWillDestroyRootWindowController() is called (if it hasn't been already). |
| window_manager_.reset(); |
| + |
| +#if defined(OS_CHROMEOS) |
| + chromeos::DBusThreadManager::Shutdown(); |
| +#endif |
| } |
| void WindowManagerApplication::OnAcceleratorRegistrarDestroyed( |