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

Unified Diff: chrome/browser/chromeos/file_manager/open_with_browser.cc

Issue 580023003: Rename the drive: scheme with the externalfile: scheme. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. 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: chrome/browser/chromeos/file_manager/open_with_browser.cc
diff --git a/chrome/browser/chromeos/file_manager/open_with_browser.cc b/chrome/browser/chromeos/file_manager/open_with_browser.cc
index a1cc3c4b5f2b8e10c63ad596f1d756da3e706d6f..429883c198b362e8151ae305c2ffa1f6cd5350e2 100644
--- a/chrome/browser/chromeos/file_manager/open_with_browser.cc
+++ b/chrome/browser/chromeos/file_manager/open_with_browser.cc
@@ -11,6 +11,7 @@
#include "base/threading/sequenced_worker_pool.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/chromeos/drive/file_system_util.h"
+#include "chrome/browser/chromeos/fileapi/external_file_url_util.h"
#include "chrome/browser/drive/drive_api_util.h"
#include "chrome/browser/plugins/plugin_prefs.h"
#include "chrome/browser/profiles/profile_manager.h"
@@ -139,7 +140,7 @@ bool OpenFileWithBrowser(Profile* profile, const base::FilePath& file_path) {
GURL page_url = net::FilePathToFileURL(file_path);
// Override drive resource to point to internal handler instead of file URL.
if (drive::util::IsUnderDriveMountPoint(file_path)) {
- page_url = drive::util::FilePathToDriveURL(
+ page_url = chromeos::FilePathToExternalFileURL(
drive::util::ExtractDrivePath(file_path));
}
OpenNewTab(profile, page_url);
@@ -149,7 +150,7 @@ bool OpenFileWithBrowser(Profile* profile, const base::FilePath& file_path) {
if (drive::util::HasHostedDocumentExtension(file_path)) {
if (drive::util::IsUnderDriveMountPoint(file_path)) {
// The file is on Google Docs. Open with drive URL.
- GURL url = drive::util::FilePathToDriveURL(
+ GURL url = chromeos::FilePathToExternalFileURL(
drive::util::ExtractDrivePath(file_path));
OpenNewTab(profile, url);
} else {

Powered by Google App Engine
This is Rietveld 408576698