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

Unified Diff: ui/compositor/compositor.cc

Issue 943763004: cc: Remove the unused compositor thread variable and interface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: compositorthread: build Created 5 years, 10 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 | « ui/compositor/compositor.h ('k') | ui/compositor/test/in_process_context_factory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/compositor/compositor.cc
diff --git a/ui/compositor/compositor.cc b/ui/compositor/compositor.cc
index 5f2a43bba0f68316d9b4c10c294454c9a0bc1f30..7989858e7100861c50d76a79e55f168e53c97778 100644
--- a/ui/compositor/compositor.cc
+++ b/ui/compositor/compositor.cc
@@ -72,7 +72,6 @@ Compositor::Compositor(gfx::AcceleratedWidget widget,
root_layer_(NULL),
widget_(widget),
surface_id_allocator_(context_factory->CreateSurfaceIdAllocator()),
- compositor_thread_loop_(context_factory->GetCompositorMessageLoop()),
task_runner_(task_runner),
vsync_manager_(new CompositorVSyncManager()),
device_scale_factor_(0.0f),
@@ -137,25 +136,10 @@ Compositor::Compositor(gfx::AcceleratedWidget widget,
settings.hud_typeface = ui::GetHudTypeface();
base::TimeTicks before_create = base::TimeTicks::Now();
- if (compositor_thread_loop_.get()) {
- host_ = cc::LayerTreeHost::CreateThreaded(
- this,
- context_factory_->GetSharedBitmapManager(),
- context_factory_->GetGpuMemoryBufferManager(),
- settings,
- task_runner_,
- compositor_thread_loop_,
- nullptr);
- } else {
- host_ = cc::LayerTreeHost::CreateSingleThreaded(
- this,
- this,
- context_factory_->GetSharedBitmapManager(),
- context_factory_->GetGpuMemoryBufferManager(),
- settings,
- task_runner_,
- nullptr);
- }
+ host_ = cc::LayerTreeHost::CreateSingleThreaded(
+ this, this, context_factory_->GetSharedBitmapManager(),
+ context_factory_->GetGpuMemoryBufferManager(), settings, task_runner_,
+ nullptr);
UMA_HISTOGRAM_TIMES("GPU.CreateBrowserCompositor",
base::TimeTicks::Now() - before_create);
host_->SetRootLayer(root_web_layer_);
@@ -354,14 +338,6 @@ void Compositor::DidCommitAndDrawFrame() {
}
void Compositor::DidCompleteSwapBuffers() {
- // DidPostSwapBuffers is a SingleThreadProxy-only feature. Synthetically
- // generate OnCompositingStarted messages for the threaded case so that
- // OnCompositingStarted/OnCompositingEnded messages match.
- if (compositor_thread_loop_.get()) {
- base::TimeTicks start_time = gfx::FrameTime::Now();
- FOR_EACH_OBSERVER(CompositorObserver, observer_list_,
- OnCompositingStarted(this, start_time));
- }
FOR_EACH_OBSERVER(CompositorObserver, observer_list_,
OnCompositingEnded(this));
}
« no previous file with comments | « ui/compositor/compositor.h ('k') | ui/compositor/test/in_process_context_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698