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

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

Issue 10834115: Drive: Mount/Unmount GoogleDrive on Files App when the file system is mounted/unmounted. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Add a comment. 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 cdf10bf572e98391cd9ebc0e212f36965206f5d5..fa616e0382f6583c41bc1edc7671674423c16cb5 100644
--- a/chrome/browser/chromeos/gdata/gdata_system_service.cc
+++ b/chrome/browser/chromeos/gdata/gdata_system_service.cc
@@ -7,12 +7,12 @@
#include "base/bind.h"
#include "base/bind_helpers.h"
#include "chrome/browser/browser_process.h"
+#include "chrome/browser/chromeos/extensions/file_browser_event_router.h"
#include "chrome/browser/chromeos/gdata/drive_webapps_registry.h"
#include "chrome/browser/chromeos/gdata/gdata_contacts_service.h"
#include "chrome/browser/chromeos/gdata/gdata_documents_service.h"
#include "chrome/browser/chromeos/gdata/gdata_download_observer.h"
#include "chrome/browser/chromeos/gdata/gdata_file_system.h"
-#include "chrome/browser/chromeos/gdata/gdata_file_system_proxy.h"
#include "chrome/browser/chromeos/gdata/gdata_sync_client.h"
#include "chrome/browser/chromeos/gdata/gdata_uploader.h"
#include "chrome/browser/chromeos/gdata/gdata_util.h"
@@ -20,10 +20,7 @@
#include "chrome/browser/download/download_service_factory.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/profiles/profile_dependency_manager.h"
-#include "content/public/browser/browser_context.h"
#include "content/public/browser/browser_thread.h"
-#include "webkit/fileapi/file_system_context.h"
-#include "webkit/fileapi/file_system_mount_point_provider.h"
using content::BrowserContext;
using content::BrowserThread;
@@ -106,23 +103,11 @@ void GDataSystemService::Shutdown() {
void GDataSystemService::AddDriveMountPoint() {
if (!gdata::util::IsGDataAvailable(profile_))
return;
-
- const FilePath mount_point = gdata::util::GetGDataMountPointPath();
- fileapi::ExternalFileSystemMountPointProvider* provider =
- BrowserContext::GetFileSystemContext(profile_)->external_provider();
- if (provider && !provider->HasMountPoint(mount_point)) {
- provider->AddRemoteMountPoint(
- mount_point,
- new GDataFileSystemProxy(file_system_.get()));
- }
+ file_system_->AddDriveMountPoint();
}
void GDataSystemService::RemoveDriveMountPoint() {
- const FilePath mount_point = gdata::util::GetGDataMountPointPath();
- fileapi::ExternalFileSystemMountPointProvider* provider =
- BrowserContext::GetFileSystemContext(profile_)->external_provider();
- if (provider && provider->HasMountPoint(mount_point))
- provider->RemoveMountPoint(mount_point);
+ file_system_->RemoveDriveMountPoint();
}
//===================== GDataSystemServiceFactory =============================

Powered by Google App Engine
This is Rietveld 408576698