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

Unified Diff: chrome/browser/chromeos/gdata/gdata_system_service.cc

Issue 10693109: Use Drive v2 API: enable behind --enable-drive-api flag (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 5 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: chrome/browser/chromeos/gdata/gdata_system_service.cc
diff --git a/chrome/browser/chromeos/gdata/gdata_system_service.cc b/chrome/browser/chromeos/gdata/gdata_system_service.cc
index fd7f7f14e9fd9a7b98c47d5d3d916b020acfefec..7b18ad0201696853413cf11218fac879dc3b4043 100644
--- a/chrome/browser/chromeos/gdata/gdata_system_service.cc
+++ b/chrome/browser/chromeos/gdata/gdata_system_service.cc
@@ -6,6 +6,7 @@
#include "base/bind.h"
#include "base/bind_helpers.h"
+#include "base/command_line.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/download/download_service.h"
#include "chrome/browser/download/download_service_factory.h"
@@ -19,6 +20,7 @@
#include "chrome/browser/chromeos/gdata/gdata_util.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/profiles/profile_dependency_manager.h"
+#include "chrome/common/chrome_switches.h"
#include "content/public/browser/browser_context.h"
#include "content/public/browser/browser_thread.h"
#include "webkit/fileapi/file_system_context.h"
@@ -63,8 +65,15 @@ GDataSystemService::~GDataSystemService() {
void GDataSystemService::Initialize() {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
+
+ if (CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kEnableDriveV2Api)) {
+ DVLOG(1) << "Using Drive v2 API.";
+ use_drive_api_ = true;
+ }
+
sync_client_->Initialize();
- file_system_->Initialize();
+ file_system_->Initialize(use_drive_api_);
cache_->RequestInitializeOnUIThread();
content::DownloadManager* download_manager =

Powered by Google App Engine
This is Rietveld 408576698