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

Side by Side Diff: services/native_viewport/ozone/native_viewport_app_ozone.cc

Issue 2011383002: Get rid of {Run,Terminate}MainApplication(), and more ApplicationDelegate conversion. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: rebased Created 4 years, 6 months 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "services/native_viewport/ozone/app_delegate_ozone.h" 5 #include "services/native_viewport/ozone/native_viewport_app_ozone.h"
6 #include "ui/ozone/public/ipc_init_helper_mojo.h" 6 #include "ui/ozone/public/ipc_init_helper_mojo.h"
7 #include "ui/ozone/public/ozone_platform.h" 7 #include "ui/ozone/public/ozone_platform.h"
8 8
9 namespace native_viewport { 9 namespace native_viewport {
10 10
11 void NativeViewportOzoneAppDelegate::Initialize( 11 void NativeViewportAppOzone::OnInitialize() {
12 mojo::ApplicationImpl* application) { 12 NativeViewportApp::OnInitialize();
13 NativeViewportAppDelegate::Initialize(application);
14 13
15 ui::OzonePlatform::InitializeForUI(); 14 ui::OzonePlatform::InitializeForUI();
16 15
17 auto ipc_init_helper = static_cast<ui::IpcInitHelperMojo*>( 16 auto ipc_init_helper = static_cast<ui::IpcInitHelperMojo*>(
18 ui::OzonePlatform::GetInstance()->GetIpcInitHelperOzone()); 17 ui::OzonePlatform::GetInstance()->GetIpcInitHelperOzone());
19 18
20 ipc_init_helper->HostInitialize(application); 19 ipc_init_helper->HostInitialize(shell());
21 ipc_init_helper->GpuInitialize(application); 20 ipc_init_helper->GpuInitialize(shell());
22 21
23 display_manager_.reset(new DisplayManager()); 22 display_manager_.reset(new DisplayManager());
24 } 23 }
25 24
26 bool NativeViewportOzoneAppDelegate::ConfigureIncomingConnection( 25 bool NativeViewportAppOzone::OnAcceptConnection(
27 ServiceProviderImpl* service_provider_impl) { 26 ServiceProviderImpl* service_provider_impl) {
28 if (!NativeViewportAppDelegate::ConfigureIncomingConnection( 27 if (!NativeViewportApp::OnAcceptConnection(service_provider_impl))
29 service_provider_impl))
30 return false; 28 return false;
31 29
32 auto ipc_init_helper = static_cast<ui::IpcInitHelperMojo*>( 30 auto ipc_init_helper = static_cast<ui::IpcInitHelperMojo*>(
33 ui::OzonePlatform::GetInstance()->GetIpcInitHelperOzone()); 31 ui::OzonePlatform::GetInstance()->GetIpcInitHelperOzone());
34 32
35 ipc_init_helper->HostConfigureIncomingConnection(connection); 33 ipc_init_helper->HostAcceptConnection(service_provider_impl);
36 ipc_init_helper->GpuConfigureIncomingConnection(connection); 34 ipc_init_helper->GpuAcceptConnection(service_provider_impl);
37 35
38 return true; 36 return true;
39 } 37 }
40 38
41 } // namespace native_viewport 39 } // namespace native_viewport
OLDNEW
« no previous file with comments | « services/native_viewport/ozone/native_viewport_app_ozone.h ('k') | services/prediction/prediction_service_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698