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

Unified Diff: cc/surfaces/display.cc

Issue 2286273003: Make cc::Display not own its BeginFrameSource (Closed)
Patch Set: Fix webview Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/surfaces/display.h ('k') | cc/surfaces/display_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/surfaces/display.cc
diff --git a/cc/surfaces/display.cc b/cc/surfaces/display.cc
index 6d024e562fb27a0df7091e68a4feb1eb452d75ee..b326a78c4f6902ba36d1a8f06ab8ad5824ac2a78 100644
--- a/cc/surfaces/display.cc
+++ b/cc/surfaces/display.cc
@@ -33,14 +33,14 @@ namespace cc {
Display::Display(SharedBitmapManager* bitmap_manager,
gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager,
const RendererSettings& settings,
- std::unique_ptr<BeginFrameSource> begin_frame_source,
+ BeginFrameSource* begin_frame_source,
std::unique_ptr<OutputSurface> output_surface,
std::unique_ptr<DisplayScheduler> scheduler,
std::unique_ptr<TextureMailboxDeleter> texture_mailbox_deleter)
: bitmap_manager_(bitmap_manager),
gpu_memory_buffer_manager_(gpu_memory_buffer_manager),
settings_(settings),
- begin_frame_source_(std::move(begin_frame_source)),
+ begin_frame_source_(begin_frame_source),
output_surface_(std::move(output_surface)),
scheduler_(std::move(scheduler)),
texture_mailbox_deleter_(std::move(texture_mailbox_deleter)) {
@@ -54,7 +54,7 @@ Display::~Display() {
// Only do this if Initialize() happened.
if (client_) {
if (begin_frame_source_)
- surface_manager_->UnregisterBeginFrameSource(begin_frame_source_.get());
+ surface_manager_->UnregisterBeginFrameSource(begin_frame_source_);
surface_manager_->RemoveObserver(this);
}
if (aggregator_) {
@@ -80,7 +80,7 @@ void Display::Initialize(DisplayClient* client,
// This must be done in Initialize() so that the caller can delay this until
// they are ready to receive a BeginFrameSource.
if (begin_frame_source_) {
- surface_manager_->RegisterBeginFrameSource(begin_frame_source_.get(),
+ surface_manager_->RegisterBeginFrameSource(begin_frame_source_,
compositor_surface_namespace_);
}
« no previous file with comments | « cc/surfaces/display.h ('k') | cc/surfaces/display_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698