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

Unified Diff: webkit/fileapi/file_system_util.cc

Issue 6810037: File API changes needed for safely passing user selected file entities from the file browser comp... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 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 | « webkit/fileapi/file_system_util.h ('k') | webkit/fileapi/sandbox_mount_point_provider.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/fileapi/file_system_util.cc
===================================================================
--- webkit/fileapi/file_system_util.cc (revision 81835)
+++ webkit/fileapi/file_system_util.cc (working copy)
@@ -15,10 +15,14 @@
namespace fileapi {
-static const char kPersistentDir[] = "/persistent/";
-static const char kTemporaryDir[] = "/temporary/";
-static const char kLocalDir[] = "/local/";
+const char kPersistentDir[] = "/persistent/";
+const char kTemporaryDir[] = "/temporary/";
+const char kExternalDir[] = "/external/";
+const char kPersistentName[] = "Persistent";
+const char kTemporaryName[] = "Temporary";
+const char kExternalName[] = "External";
+
bool CrackFileSystemURL(const GURL& url, GURL* origin_url, FileSystemType* type,
FilePath* file_path) {
GURL origin;
@@ -77,9 +81,9 @@
} else if (path.compare(0, strlen(kTemporaryDir), kTemporaryDir) == 0) {
file_system_type = kFileSystemTypeTemporary;
path = path.substr(strlen(kTemporaryDir));
- } else if (path.compare(0, strlen(kLocalDir), kLocalDir) == 0) {
- file_system_type = kFileSystemTypeLocal;
- path = path.substr(strlen(kLocalDir));
+ } else if (path.compare(0, strlen(kExternalDir), kExternalDir) == 0) {
+ file_system_type = kFileSystemTypeExternal;
+ path = path.substr(strlen(kExternalDir));
} else {
return false;
}
@@ -114,8 +118,8 @@
case kFileSystemTypePersistent:
path += (kPersistentDir + 1); // We don't want the leading slash.
break;
- case kFileSystemTypeLocal:
- path += (kLocalDir + 1); // We don't want the leading slash.
+ case kFileSystemTypeExternal:
+ path += (kExternalDir + 1); // We don't want the leading slash.
break;
default:
NOTREACHED();
« no previous file with comments | « webkit/fileapi/file_system_util.h ('k') | webkit/fileapi/sandbox_mount_point_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698