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

Unified Diff: cc/output/context_cache_controller.h

Issue 2286873003: Provide TaskRunner to ContextCacheController (Closed)
Patch Set: cleanup 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
Index: cc/output/context_cache_controller.h
diff --git a/cc/output/context_cache_controller.h b/cc/output/context_cache_controller.h
index fb1ab9f4efb59a3273b158d6ac5c31dd555b6d66..03f7e2cd74f9117e11cb95ac6db4a747199301f7 100644
--- a/cc/output/context_cache_controller.h
+++ b/cc/output/context_cache_controller.h
@@ -9,10 +9,15 @@
#include <memory>
#include "base/macros.h"
+#include "base/memory/ref_counted.h"
#include "cc/base/cc_export.h"
class GrContext;
+namespace base {
+class SingleThreadTaskRunner;
+}
+
namespace gpu {
class ContextSupport;
}
@@ -41,7 +46,9 @@ class CC_EXPORT ContextCacheController {
bool released_ = false;
};
- explicit ContextCacheController(gpu::ContextSupport* context_support);
+ ContextCacheController(
+ gpu::ContextSupport* context_support,
+ scoped_refptr<base::SingleThreadTaskRunner> task_runner);
virtual ~ContextCacheController();
void SetGrContext(GrContext* gr_context);
@@ -64,6 +71,7 @@ class CC_EXPORT ContextCacheController {
private:
gpu::ContextSupport* context_support_;
+ scoped_refptr<base::SingleThreadTaskRunner> task_runner_;
GrContext* gr_context_ = nullptr;
uint32_t num_clients_visible_ = 0;

Powered by Google App Engine
This is Rietveld 408576698