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

Side by Side Diff: ui/ozone/platform/drm/mus_thread_proxy.cc

Issue 2613493002: Fix namespace for src/ui/display/. (Closed)
Patch Set: Rebase. Created 3 years, 11 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
« no previous file with comments | « ui/ozone/platform/drm/mus_thread_proxy.h ('k') | ui/ozone/platform/drm/ozone_platform_gbm.cc » ('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 "ui/ozone/platform/drm/mus_thread_proxy.h" 5 #include "ui/ozone/platform/drm/mus_thread_proxy.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/single_thread_task_runner.h" 8 #include "base/single_thread_task_runner.h"
9 #include "base/task_runner.h" 9 #include "base/task_runner.h"
10 #include "base/threading/thread_task_runner_handle.h" 10 #include "base/threading/thread_task_runner_handle.h"
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
283 DCHECK(on_window_server_thread_.CalledOnValidThread()); 283 DCHECK(on_window_server_thread_.CalledOnValidThread());
284 auto callback = base::Bind(&MusThreadProxy::GpuGetHDCPStateCallback, 284 auto callback = base::Bind(&MusThreadProxy::GpuGetHDCPStateCallback,
285 weak_ptr_factory_.GetWeakPtr()); 285 weak_ptr_factory_.GetWeakPtr());
286 drm_thread_->task_runner()->PostTask( 286 drm_thread_->task_runner()->PostTask(
287 FROM_HERE, 287 FROM_HERE,
288 base::Bind(&DrmThread::GetHDCPState, base::Unretained(drm_thread_), 288 base::Bind(&DrmThread::GetHDCPState, base::Unretained(drm_thread_),
289 display_id, CreateSafeCallback(callback))); 289 display_id, CreateSafeCallback(callback)));
290 return true; 290 return true;
291 } 291 }
292 292
293 bool MusThreadProxy::GpuSetHDCPState(int64_t display_id, HDCPState state) { 293 bool MusThreadProxy::GpuSetHDCPState(int64_t display_id,
294 display::HDCPState state) {
294 DCHECK(on_window_server_thread_.CalledOnValidThread()); 295 DCHECK(on_window_server_thread_.CalledOnValidThread());
295 DCHECK(drm_thread_->IsRunning()); 296 DCHECK(drm_thread_->IsRunning());
296 auto callback = base::Bind(&MusThreadProxy::GpuSetHDCPStateCallback, 297 auto callback = base::Bind(&MusThreadProxy::GpuSetHDCPStateCallback,
297 weak_ptr_factory_.GetWeakPtr()); 298 weak_ptr_factory_.GetWeakPtr());
298 drm_thread_->task_runner()->PostTask( 299 drm_thread_->task_runner()->PostTask(
299 FROM_HERE, 300 FROM_HERE,
300 base::Bind(&DrmThread::SetHDCPState, base::Unretained(drm_thread_), 301 base::Bind(&DrmThread::SetHDCPState, base::Unretained(drm_thread_),
301 display_id, state, CreateSafeCallback(callback))); 302 display_id, state, CreateSafeCallback(callback)));
302 return true; 303 return true;
303 } 304 }
304 305
305 bool MusThreadProxy::GpuSetColorCorrection( 306 bool MusThreadProxy::GpuSetColorCorrection(
306 int64_t id, 307 int64_t id,
307 const std::vector<GammaRampRGBEntry>& degamma_lut, 308 const std::vector<display::GammaRampRGBEntry>& degamma_lut,
308 const std::vector<GammaRampRGBEntry>& gamma_lut, 309 const std::vector<display::GammaRampRGBEntry>& gamma_lut,
309 const std::vector<float>& correction_matrix) { 310 const std::vector<float>& correction_matrix) {
310 DCHECK(drm_thread_->IsRunning()); 311 DCHECK(drm_thread_->IsRunning());
311 DCHECK(on_window_server_thread_.CalledOnValidThread()); 312 DCHECK(on_window_server_thread_.CalledOnValidThread());
312 drm_thread_->task_runner()->PostTask( 313 drm_thread_->task_runner()->PostTask(
313 FROM_HERE, 314 FROM_HERE,
314 base::Bind(&DrmThread::SetColorCorrection, base::Unretained(drm_thread_), 315 base::Bind(&DrmThread::SetColorCorrection, base::Unretained(drm_thread_),
315 id, degamma_lut, gamma_lut, correction_matrix)); 316 id, degamma_lut, gamma_lut, correction_matrix));
316 return true; 317 return true;
317 } 318 }
318 319
(...skipping 27 matching lines...) Expand all
346 display_manager_->GpuTookDisplayControl(success); 347 display_manager_->GpuTookDisplayControl(success);
347 } 348 }
348 349
349 void MusThreadProxy::GpuRelinquishDisplayControlCallback(bool success) const { 350 void MusThreadProxy::GpuRelinquishDisplayControlCallback(bool success) const {
350 DCHECK(on_window_server_thread_.CalledOnValidThread()); 351 DCHECK(on_window_server_thread_.CalledOnValidThread());
351 display_manager_->GpuRelinquishedDisplayControl(success); 352 display_manager_->GpuRelinquishedDisplayControl(success);
352 } 353 }
353 354
354 void MusThreadProxy::GpuGetHDCPStateCallback(int64_t display_id, 355 void MusThreadProxy::GpuGetHDCPStateCallback(int64_t display_id,
355 bool success, 356 bool success,
356 HDCPState state) const { 357 display::HDCPState state) const {
357 DCHECK(on_window_server_thread_.CalledOnValidThread()); 358 DCHECK(on_window_server_thread_.CalledOnValidThread());
358 display_manager_->GpuReceivedHDCPState(display_id, success, state); 359 display_manager_->GpuReceivedHDCPState(display_id, success, state);
359 } 360 }
360 361
361 void MusThreadProxy::GpuSetHDCPStateCallback(int64_t display_id, 362 void MusThreadProxy::GpuSetHDCPStateCallback(int64_t display_id,
362 bool success) const { 363 bool success) const {
363 DCHECK(on_window_server_thread_.CalledOnValidThread()); 364 DCHECK(on_window_server_thread_.CalledOnValidThread());
364 display_manager_->GpuUpdatedHDCPState(display_id, success); 365 display_manager_->GpuUpdatedHDCPState(display_id, success);
365 } 366 }
366 367
367 } // namespace ui 368 } // namespace ui
OLDNEW
« no previous file with comments | « ui/ozone/platform/drm/mus_thread_proxy.h ('k') | ui/ozone/platform/drm/ozone_platform_gbm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698