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

Unified Diff: blimp/client/support/compositor/blimp_context_provider.cc

Issue 2286873003: Provide TaskRunner to ContextCacheController (Closed)
Patch Set: fix unittests Created 4 years, 3 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
Index: blimp/client/support/compositor/blimp_context_provider.cc
diff --git a/blimp/client/support/compositor/blimp_context_provider.cc b/blimp/client/support/compositor/blimp_context_provider.cc
index 5e0d3b23a23e837d4b737a4a8dac6320af41c5b9..e5541e1c780b136f9b2fb76a4b61c2a31c677417 100644
--- a/blimp/client/support/compositor/blimp_context_provider.cc
+++ b/blimp/client/support/compositor/blimp_context_provider.cc
@@ -7,6 +7,7 @@
#include "base/bind.h"
#include "base/callback_helpers.h"
#include "base/lazy_instance.h"
+#include "base/threading/thread_task_runner_handle.h"
#include "cc/output/context_cache_controller.h"
#include "gpu/command_buffer/client/gl_in_process_context.h"
#include "gpu/command_buffer/client/gles2_implementation.h"
@@ -46,12 +47,12 @@ BlimpContextProvider::BlimpContextProvider(
nullptr /* service */, nullptr /* surface */,
widget == gfx::kNullAcceleratedWidget /* is_offscreen */, widget,
nullptr /* share_context */, attribs_for_gles2, gpu::SharedMemoryLimits(),
- gpu_memory_buffer_manager, nullptr /* memory_limits */));
+ gpu_memory_buffer_manager, nullptr /* memory_limits */,
+ base::ThreadTaskRunnerHandle::Get()));
context_->GetImplementation()->SetLostContextCallback(
base::Bind(&BlimpContextProvider::OnLostContext, base::Unretained(this)));
-
- cache_controller_.reset(
- new cc::ContextCacheController(context_->GetImplementation()));
+ cache_controller_.reset(new cc::ContextCacheController(
+ context_->GetImplementation(), base::ThreadTaskRunnerHandle::Get()));
}
BlimpContextProvider::~BlimpContextProvider() {

Powered by Google App Engine
This is Rietveld 408576698