Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(176)

Side by Side Diff: chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.cc

Issue 2525563003: mash: Change CastConfigDelegate to a mojoified CastConfigClient. (Closed)
Patch Set: move dep to chromeos section Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.h ('k') | chrome/test/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/root_window_controller.h" 7 #include "ash/root_window_controller.h"
8 #include "ash/shell.h" 8 #include "ash/shell.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
11 #include "base/macros.h" 11 #include "base/macros.h"
12 #include "base/memory/ptr_util.h" 12 #include "base/memory/ptr_util.h"
13 #include "build/build_config.h" 13 #include "build/build_config.h"
14 #include "chrome/browser/chrome_browser_main.h" 14 #include "chrome/browser/chrome_browser_main.h"
15 #include "chrome/browser/ui/ash/ash_init.h" 15 #include "chrome/browser/ui/ash/ash_init.h"
16 #include "chrome/browser/ui/ash/ash_util.h" 16 #include "chrome/browser/ui/ash/ash_util.h"
17 #include "chrome/browser/ui/ash/cast_config_client_media_router.h"
17 #include "chrome/browser/ui/ash/launcher/chrome_launcher_controller_mus.h" 18 #include "chrome/browser/ui/ash/launcher/chrome_launcher_controller_mus.h"
18 #include "chrome/browser/ui/views/ash/tab_scrubber.h" 19 #include "chrome/browser/ui/views/ash/tab_scrubber.h"
19 #include "chrome/browser/ui/views/frame/immersive_context_mus.h" 20 #include "chrome/browser/ui/views/frame/immersive_context_mus.h"
20 #include "chrome/browser/ui/views/frame/immersive_handler_factory_mus.h" 21 #include "chrome/browser/ui/views/frame/immersive_handler_factory_mus.h"
21 #include "chrome/common/chrome_switches.h" 22 #include "chrome/common/chrome_switches.h"
22 #include "ui/aura/env.h" 23 #include "ui/aura/env.h"
23 #include "ui/keyboard/content/keyboard.h" 24 #include "ui/keyboard/content/keyboard.h"
24 #include "ui/keyboard/keyboard_controller.h" 25 #include "ui/keyboard/keyboard_controller.h"
25 26
26 #if defined(OS_CHROMEOS) 27 #if defined(OS_CHROMEOS)
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 61
61 void ChromeBrowserMainExtraPartsAsh::PostProfileInit() { 62 void ChromeBrowserMainExtraPartsAsh::PostProfileInit() {
62 if (chrome::IsRunningInMash()) { 63 if (chrome::IsRunningInMash()) {
63 DCHECK(!ash::Shell::HasInstance()); 64 DCHECK(!ash::Shell::HasInstance());
64 DCHECK(!ChromeLauncherController::instance()); 65 DCHECK(!ChromeLauncherController::instance());
65 chrome_launcher_controller_mus_ = 66 chrome_launcher_controller_mus_ =
66 base::MakeUnique<ChromeLauncherControllerMus>(); 67 base::MakeUnique<ChromeLauncherControllerMus>();
67 chrome_launcher_controller_mus_->Init(); 68 chrome_launcher_controller_mus_->Init();
68 } 69 }
69 70
71 cast_config_client_media_router_ =
72 base::MakeUnique<CastConfigClientMediaRouter>();
73
70 if (!ash::Shell::HasInstance()) 74 if (!ash::Shell::HasInstance())
71 return; 75 return;
72 76
73 // Initialize TabScrubber after the Ash Shell has been initialized. 77 // Initialize TabScrubber after the Ash Shell has been initialized.
74 TabScrubber::GetInstance(); 78 TabScrubber::GetInstance();
75 // Activate virtual keyboard after profile is initialized. It depends on the 79 // Activate virtual keyboard after profile is initialized. It depends on the
76 // default profile. 80 // default profile.
77 ash::Shell::GetPrimaryRootWindowController()->ActivateKeyboard( 81 ash::Shell::GetPrimaryRootWindowController()->ActivateKeyboard(
78 keyboard::KeyboardController::GetInstance()); 82 keyboard::KeyboardController::GetInstance());
79 } 83 }
80 84
81 void ChromeBrowserMainExtraPartsAsh::PostMainMessageLoopRun() { 85 void ChromeBrowserMainExtraPartsAsh::PostMainMessageLoopRun() {
82 #if defined(OS_CHROMEOS) 86 #if defined(OS_CHROMEOS)
83 vpn_list_forwarder_.reset(); 87 vpn_list_forwarder_.reset();
84 system_tray_client_.reset(); 88 system_tray_client_.reset();
89 cast_config_client_media_router_.reset();
85 #endif 90 #endif
86 chrome::CloseAsh(); 91 chrome::CloseAsh();
87 } 92 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/ash/chrome_browser_main_extra_parts_ash.h ('k') | chrome/test/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698