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

Side by Side Diff: ash/common/mojo_interface_factory.cc

Issue 2549903002: mash: Reverse the responsibilities of the NewWindowClient. (Closed)
Patch Set: jamescook comments 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 | « ash/common/accelerators/accelerator_controller.cc ('k') | ash/common/new_window_client_proxy.h » ('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 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/common/mojo_interface_factory.h" 5 #include "ash/common/mojo_interface_factory.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "ash/common/accelerators/accelerator_controller.h" 9 #include "ash/common/accelerators/accelerator_controller.h"
10 #include "ash/common/cast_config_controller.h" 10 #include "ash/common/cast_config_controller.h"
11 #include "ash/common/new_window_controller.h"
11 #include "ash/common/shelf/shelf_controller.h" 12 #include "ash/common/shelf/shelf_controller.h"
12 #include "ash/common/shutdown_controller.h" 13 #include "ash/common/shutdown_controller.h"
13 #include "ash/common/system/locale/locale_notification_controller.h" 14 #include "ash/common/system/locale/locale_notification_controller.h"
14 #include "ash/common/system/tray/system_tray_controller.h" 15 #include "ash/common/system/tray/system_tray_controller.h"
15 #include "ash/common/wallpaper/wallpaper_controller.h" 16 #include "ash/common/wallpaper/wallpaper_controller.h"
16 #include "ash/common/wm/maximize_mode/maximize_mode_controller.h" 17 #include "ash/common/wm/maximize_mode/maximize_mode_controller.h"
17 #include "ash/common/wm_shell.h" 18 #include "ash/common/wm_shell.h"
18 #include "base/bind.h" 19 #include "base/bind.h"
19 #include "services/service_manager/public/cpp/interface_registry.h" 20 #include "services/service_manager/public/cpp/interface_registry.h"
20 21
(...skipping 13 matching lines...) Expand all
34 void BindCastConfigOnMainThread(mojom::CastConfigRequest request) { 35 void BindCastConfigOnMainThread(mojom::CastConfigRequest request) {
35 WmShell::Get()->cast_config()->BindRequest(std::move(request)); 36 WmShell::Get()->cast_config()->BindRequest(std::move(request));
36 } 37 }
37 38
38 void BindLocaleNotificationControllerOnMainThread( 39 void BindLocaleNotificationControllerOnMainThread(
39 mojom::LocaleNotificationControllerRequest request) { 40 mojom::LocaleNotificationControllerRequest request) {
40 WmShell::Get()->locale_notification_controller()->BindRequest( 41 WmShell::Get()->locale_notification_controller()->BindRequest(
41 std::move(request)); 42 std::move(request));
42 } 43 }
43 44
45 void BindNewWindowControllerRequestOnMainThread(
46 mojom::NewWindowControllerRequest request) {
47 WmShell::Get()->new_window_controller()->BindRequest(std::move(request));
48 }
49
44 void BindShelfRequestOnMainThread(mojom::ShelfControllerRequest request) { 50 void BindShelfRequestOnMainThread(mojom::ShelfControllerRequest request) {
45 WmShell::Get()->shelf_controller()->BindRequest(std::move(request)); 51 WmShell::Get()->shelf_controller()->BindRequest(std::move(request));
46 } 52 }
47 53
48 void BindShutdownControllerRequestOnMainThread( 54 void BindShutdownControllerRequestOnMainThread(
49 mojom::ShutdownControllerRequest request) { 55 mojom::ShutdownControllerRequest request) {
50 WmShell::Get()->shutdown_controller()->BindRequest(std::move(request)); 56 WmShell::Get()->shutdown_controller()->BindRequest(std::move(request));
51 } 57 }
52 58
53 void BindSystemTrayRequestOnMainThread(mojom::SystemTrayRequest request) { 59 void BindSystemTrayRequestOnMainThread(mojom::SystemTrayRequest request) {
(...skipping 23 matching lines...) Expand all
77 service_manager::InterfaceRegistry* registry, 83 service_manager::InterfaceRegistry* registry,
78 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner) { 84 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner) {
79 registry->AddInterface( 85 registry->AddInterface(
80 base::Bind(&BindAcceleratorControllerRequestOnMainThread), 86 base::Bind(&BindAcceleratorControllerRequestOnMainThread),
81 main_thread_task_runner); 87 main_thread_task_runner);
82 registry->AddInterface(base::Bind(&BindCastConfigOnMainThread), 88 registry->AddInterface(base::Bind(&BindCastConfigOnMainThread),
83 main_thread_task_runner); 89 main_thread_task_runner);
84 registry->AddInterface( 90 registry->AddInterface(
85 base::Bind(&BindLocaleNotificationControllerOnMainThread), 91 base::Bind(&BindLocaleNotificationControllerOnMainThread),
86 main_thread_task_runner); 92 main_thread_task_runner);
93 registry->AddInterface(
94 base::Bind(&BindNewWindowControllerRequestOnMainThread),
95 main_thread_task_runner);
87 registry->AddInterface(base::Bind(&BindShelfRequestOnMainThread), 96 registry->AddInterface(base::Bind(&BindShelfRequestOnMainThread),
88 main_thread_task_runner); 97 main_thread_task_runner);
89 registry->AddInterface(base::Bind(&BindShutdownControllerRequestOnMainThread), 98 registry->AddInterface(base::Bind(&BindShutdownControllerRequestOnMainThread),
90 main_thread_task_runner); 99 main_thread_task_runner);
91 registry->AddInterface(base::Bind(&BindSystemTrayRequestOnMainThread), 100 registry->AddInterface(base::Bind(&BindSystemTrayRequestOnMainThread),
92 main_thread_task_runner); 101 main_thread_task_runner);
93 registry->AddInterface(base::Bind(&BindTouchViewRequestOnMainThread), 102 registry->AddInterface(base::Bind(&BindTouchViewRequestOnMainThread),
94 main_thread_task_runner); 103 main_thread_task_runner);
95 #if defined(OS_CHROMEOS) 104 #if defined(OS_CHROMEOS)
96 registry->AddInterface(base::Bind(&BindVpnListRequestOnMainThread), 105 registry->AddInterface(base::Bind(&BindVpnListRequestOnMainThread),
97 main_thread_task_runner); 106 main_thread_task_runner);
98 #endif 107 #endif
99 registry->AddInterface(base::Bind(&BindWallpaperRequestOnMainThread), 108 registry->AddInterface(base::Bind(&BindWallpaperRequestOnMainThread),
100 main_thread_task_runner); 109 main_thread_task_runner);
101 } 110 }
102 111
103 } // namespace mojo_interface_factory 112 } // namespace mojo_interface_factory
104 113
105 } // namespace ash 114 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/accelerators/accelerator_controller.cc ('k') | ash/common/new_window_client_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698