Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "ui/ozone/platform/drm/mojo/drm_host_impl.h" | |
| 6 | |
| 7 #include "base/logging.h" | |
| 8 #include "base/process/process.h" | |
| 9 #include "mojo/converters/ozone_drm_gpu/ozone_drm_gpu_type_converters.h" | |
| 10 #include "ui/ozone/public/ozone_platform.h" | |
| 11 | |
| 12 namespace ui { | |
| 13 | |
| 14 MojoDrmHostImpl::MojoDrmHostImpl( | |
| 15 mojo::InterfaceRequest<mojo::OzoneDrmHost> request) | |
| 16 : platform_support_(static_cast<ui::DrmGpuPlatformSupportHost*>( | |
| 17 ui::OzonePlatform::GetInstance() | |
| 18 ->GetGpuPlatformSupportHost())), | |
| 19 binding_(this, request.Pass()) { | |
| 20 platform_support_->OnChannelEstablished(base::Process::Current().Pid()); | |
|
jamesr
2015/08/27 19:35:47
does this need the actual pid? what does it use it
cdotstout
2015/08/27 21:28:33
Some ipc mechanisms may need it. Drm/mojo doesn't
spang
2015/08/28 19:38:20
The number is used for handling GPU process restar
| |
| 21 } | |
| 22 | |
| 23 MojoDrmHostImpl::~MojoDrmHostImpl() {} | |
| 24 | |
| 25 void MojoDrmHostImpl::UpdateNativeDisplays( | |
| 26 mojo::Array<mojo::DisplaySnapshotPtr> displays) { | |
| 27 platform_support_->get_display_manager()->OnUpdateNativeDisplays( | |
| 28 displays.To<std::vector<ui::DisplaySnapshot_Params>>()); | |
| 29 } | |
| 30 | |
| 31 void MojoDrmHostImpl::DisplayConfigured(int64_t id, bool result) { | |
| 32 platform_support_->get_display_manager()->OnDisplayConfigured(id, result); | |
| 33 } | |
| 34 | |
| 35 } // namespace ui | |
| OLD | NEW |