| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.h" | 5 #include "chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.h" |
| 6 | 6 |
| 7 #include "ash/public/cpp/mus_property_mirror_ash.h" | 7 #include "ash/public/cpp/mus_property_mirror_ash.h" |
| 8 #include "ash/public/cpp/window_properties.h" | 8 #include "ash/public/cpp/window_properties.h" |
| 9 #include "ash/root_window_controller.h" | 9 #include "ash/root_window_controller.h" |
| 10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 ui::mojom::WindowManager::kShelfItemType_Property, | 55 ui::mojom::WindowManager::kShelfItemType_Property, |
| 56 base::Bind(&ash::IsValidShelfItemType)); | 56 base::Bind(&ash::IsValidShelfItemType)); |
| 57 | 57 |
| 58 mus_client->SetMusPropertyMirror( | 58 mus_client->SetMusPropertyMirror( |
| 59 base::MakeUnique<ash::MusPropertyMirrorAsh>()); | 59 base::MakeUnique<ash::MusPropertyMirrorAsh>()); |
| 60 } | 60 } |
| 61 } | 61 } |
| 62 | 62 |
| 63 void ChromeBrowserMainExtraPartsAsh::PreProfileInit() { | 63 void ChromeBrowserMainExtraPartsAsh::PreProfileInit() { |
| 64 if (ash_util::ShouldOpenAshOnStartup()) | 64 if (ash_util::ShouldOpenAshOnStartup()) |
| 65 chrome::OpenAsh(gfx::kNullAcceleratedWidget); | 65 ash_init_ = base::MakeUnique<AshInit>(); |
| 66 | 66 |
| 67 if (ash_util::IsRunningInMash()) { | 67 if (ash_util::IsRunningInMash()) { |
| 68 immersive_context_ = base::MakeUnique<ImmersiveContextMus>(); | 68 immersive_context_ = base::MakeUnique<ImmersiveContextMus>(); |
| 69 immersive_handler_factory_ = base::MakeUnique<ImmersiveHandlerFactoryMus>(); | 69 immersive_handler_factory_ = base::MakeUnique<ImmersiveHandlerFactoryMus>(); |
| 70 } | 70 } |
| 71 | 71 |
| 72 session_controller_client_ = base::MakeUnique<SessionControllerClient>(); | 72 session_controller_client_ = base::MakeUnique<SessionControllerClient>(); |
| 73 | 73 |
| 74 // Must be available at login screen, so initialize before profile. | 74 // Must be available at login screen, so initialize before profile. |
| 75 system_tray_client_ = base::MakeUnique<SystemTrayClient>(); | 75 system_tray_client_ = base::MakeUnique<SystemTrayClient>(); |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 | 112 |
| 113 void ChromeBrowserMainExtraPartsAsh::PostMainMessageLoopRun() { | 113 void ChromeBrowserMainExtraPartsAsh::PostMainMessageLoopRun() { |
| 114 vpn_list_forwarder_.reset(); | 114 vpn_list_forwarder_.reset(); |
| 115 volume_controller_.reset(); | 115 volume_controller_.reset(); |
| 116 new_window_client_.reset(); | 116 new_window_client_.reset(); |
| 117 system_tray_client_.reset(); | 117 system_tray_client_.reset(); |
| 118 media_client_.reset(); | 118 media_client_.reset(); |
| 119 cast_config_client_media_router_.reset(); | 119 cast_config_client_media_router_.reset(); |
| 120 session_controller_client_.reset(); | 120 session_controller_client_.reset(); |
| 121 | 121 |
| 122 chrome::CloseAsh(); | 122 ash_init_.reset(); |
| 123 } | 123 } |
| OLD | NEW |