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

Unified Diff: cc/layers/delegated_frame_resource_collection.cc

Issue 485043003: cc: Use correct message loop proxy in BlockingTaskRunner (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Nits. Created 6 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: cc/layers/delegated_frame_resource_collection.cc
diff --git a/cc/layers/delegated_frame_resource_collection.cc b/cc/layers/delegated_frame_resource_collection.cc
index 5ca4eda57d761bed7998ae75964a136c979ddae9..b0e4cbf72964f6993251828a8ffd95a7900a7c30 100644
--- a/cc/layers/delegated_frame_resource_collection.cc
+++ b/cc/layers/delegated_frame_resource_collection.cc
@@ -11,7 +11,6 @@ namespace cc {
DelegatedFrameResourceCollection::DelegatedFrameResourceCollection()
: client_(NULL),
- main_thread_runner_(BlockingTaskRunner::current()),
lost_all_resources_(false),
weak_ptr_factory_(this) {
DCHECK(main_thread_checker_.CalledOnValidThread());
@@ -115,9 +114,9 @@ void DelegatedFrameResourceCollection::RefResources(
static void UnrefResourcesOnImplThread(
base::WeakPtr<DelegatedFrameResourceCollection> self,
- scoped_refptr<BlockingTaskRunner> main_thread_runner,
- const ReturnedResourceArray& returned) {
- main_thread_runner->PostTask(
+ const ReturnedResourceArray& returned,
+ BlockingTaskRunner* main_thread_task_runner) {
+ main_thread_task_runner->PostTask(
FROM_HERE,
base::Bind(
&DelegatedFrameResourceCollection::UnrefResources, self, returned));
@@ -126,8 +125,7 @@ static void UnrefResourcesOnImplThread(
ReturnCallback
DelegatedFrameResourceCollection::GetReturnResourcesCallbackForImplThread() {
return base::Bind(&UnrefResourcesOnImplThread,
- weak_ptr_factory_.GetWeakPtr(),
- main_thread_runner_);
+ weak_ptr_factory_.GetWeakPtr());
}
} // namespace cc
« no previous file with comments | « cc/layers/delegated_frame_resource_collection.h ('k') | cc/layers/delegated_frame_resource_collection_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698