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

Unified Diff: chrome/browser/chromeos/drive/drive_integration_service.cc

Issue 150163003: drive: Switch Drive mount path to per-profile one. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Review fix. Created 6 years, 10 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 | « no previous file | chrome/browser/chromeos/drive/file_system_util.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/drive/drive_integration_service.cc
diff --git a/chrome/browser/chromeos/drive/drive_integration_service.cc b/chrome/browser/chromeos/drive/drive_integration_service.cc
index 9a08bb4281f541ad1265397ef235a5a55d467af5..bd495241058e2e1900627eea221f297f2f7a1c1c 100644
--- a/chrome/browser/chromeos/drive/drive_integration_service.cc
+++ b/chrome/browser/chromeos/drive/drive_integration_service.cc
@@ -353,8 +353,10 @@ bool DriveIntegrationService::IsMounted() const {
// Look up the registered path, and just discard it.
// GetRegisteredPath() returns true if the path is available.
base::FilePath unused;
- return BrowserContext::GetMountPoints(profile_)->GetRegisteredPath(
- mount_point_name_, &unused);
+ fileapi::ExternalMountPoints* const mount_points =
+ fileapi::ExternalMountPoints::GetSystemInstance();
+ DCHECK(mount_points);
+ return mount_points->GetRegisteredPath(mount_point_name_, &unused);
}
void DriveIntegrationService::AddObserver(
@@ -431,8 +433,8 @@ void DriveIntegrationService::AddDriveMountPoint() {
util::GetDriveMountPointPath(profile_);
if (mount_point_name_.empty())
mount_point_name_ = drive_mount_point.BaseName().AsUTF8Unsafe();
- fileapi::ExternalMountPoints* mount_points =
- BrowserContext::GetMountPoints(profile_);
+ fileapi::ExternalMountPoints* const mount_points =
+ fileapi::ExternalMountPoints::GetSystemInstance();
DCHECK(mount_points);
bool success = mount_points->RegisterFileSystem(
@@ -457,8 +459,8 @@ void DriveIntegrationService::RemoveDriveMountPoint() {
FOR_EACH_OBSERVER(DriveIntegrationServiceObserver, observers_,
OnFileSystemBeingUnmounted());
- fileapi::ExternalMountPoints* mount_points =
- BrowserContext::GetMountPoints(profile_);
+ fileapi::ExternalMountPoints* const mount_points =
+ fileapi::ExternalMountPoints::GetSystemInstance();
DCHECK(mount_points);
mount_points->RevokeFileSystem(mount_point_name_);
« no previous file with comments | « no previous file | chrome/browser/chromeos/drive/file_system_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698