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

Unified Diff: chrome/browser/sync_file_system/drive/api_util.cc

Issue 17520005: drive: Pass TaskRunner to DriveUploader explicitly (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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 | « chrome/browser/drive/drive_uploader_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync_file_system/drive/api_util.cc
diff --git a/chrome/browser/sync_file_system/drive/api_util.cc b/chrome/browser/sync_file_system/drive/api_util.cc
index 76d5c77ec3de5213e57b15f715f20377635292fe..d7d7435896b7b3c32771db233244ca6a1e7d947b 100644
--- a/chrome/browser/sync_file_system/drive/api_util.cc
+++ b/chrome/browser/sync_file_system/drive/api_util.cc
@@ -11,6 +11,7 @@
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
+#include "base/threading/sequenced_worker_pool.h"
#include "base/values.h"
#include "chrome/browser/drive/drive_api_service.h"
#include "chrome/browser/drive/drive_api_util.h"
@@ -21,6 +22,7 @@
#include "chrome/browser/sync_file_system/drive_file_sync_util.h"
#include "chrome/browser/sync_file_system/logger.h"
#include "chrome/common/extensions/extension.h"
+#include "content/public/browser/browser_thread.h"
#include "extensions/common/constants.h"
#include "net/base/mime_util.h"
#include "webkit/browser/fileapi/syncable/syncable_file_system_util.h"
@@ -148,7 +150,8 @@ APIUtil::APIUtil(Profile* profile)
drive_service_->AddObserver(this);
net::NetworkChangeNotifier::AddConnectionTypeObserver(this);
- drive_uploader_.reset(new ::drive::DriveUploader(drive_service_.get()));
+ drive_uploader_.reset(new ::drive::DriveUploader(
+ drive_service_.get(), content::BrowserThread::GetBlockingPool()));
}
scoped_ptr<APIUtil> APIUtil::CreateForTesting(
@@ -1057,7 +1060,8 @@ void APIUtil::CancelAllUploads(google_apis::GDataErrorCode error) {
iter->second.Run(error, std::string(), std::string());
}
upload_callback_map_.clear();
- drive_uploader_.reset(new ::drive::DriveUploader(drive_service_.get()));
+ drive_uploader_.reset(new ::drive::DriveUploader(
+ drive_service_.get(), content::BrowserThread::GetBlockingPool()));
}
std::string APIUtil::GetRootResourceId() const {
« no previous file with comments | « chrome/browser/drive/drive_uploader_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698