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

Unified Diff: content/common/file_system/webfilesystem_impl.cc

Issue 6904063: String->URL cleanup, chromium-side. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove unnecessary WebURL constructors. Created 9 years, 7 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 | « content/common/file_system/webfilesystem_impl.h ('k') | webkit/fileapi/file_system_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/file_system/webfilesystem_impl.cc
diff --git a/content/common/file_system/webfilesystem_impl.cc b/content/common/file_system/webfilesystem_impl.cc
index 38f1d2a0f046841f8766aceed0b0b1c65fb3f8fd..977bec4aeee1133ee0e954b9bc2274eb444b5ad7 100644
--- a/content/common/file_system/webfilesystem_impl.cc
+++ b/content/common/file_system/webfilesystem_impl.cc
@@ -11,19 +11,21 @@
#include "third_party/WebKit/Source/WebKit/chromium/public/WebFileInfo.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebFileSystemCallbacks.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebString.h"
+#include "third_party/WebKit/Source/WebKit/chromium/public/WebURL.h"
#include "webkit/glue/webkit_glue.h"
using WebKit::WebFileInfo;
using WebKit::WebFileSystemCallbacks;
using WebKit::WebFileSystemEntry;
using WebKit::WebString;
+using WebKit::WebURL;
using WebKit::WebVector;
WebFileSystemImpl::WebFileSystemImpl() {
}
-void WebFileSystemImpl::move(const WebString& src_path,
- const WebString& dest_path,
+void WebFileSystemImpl::move(const WebURL& src_path,
+ const WebURL& dest_path,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
ChildThread::current()->file_system_dispatcher();
@@ -32,8 +34,8 @@ void WebFileSystemImpl::move(const WebString& src_path,
new WebFileSystemCallbackDispatcher(callbacks));
}
-void WebFileSystemImpl::copy(const WebString& src_path,
- const WebString& dest_path,
+void WebFileSystemImpl::copy(const WebURL& src_path,
+ const WebURL& dest_path,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
ChildThread::current()->file_system_dispatcher();
@@ -42,7 +44,7 @@ void WebFileSystemImpl::copy(const WebString& src_path,
new WebFileSystemCallbackDispatcher(callbacks));
}
-void WebFileSystemImpl::remove(const WebString& path,
+void WebFileSystemImpl::remove(const WebURL& path,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
ChildThread::current()->file_system_dispatcher();
@@ -51,7 +53,7 @@ void WebFileSystemImpl::remove(const WebString& path,
new WebFileSystemCallbackDispatcher(callbacks));
}
-void WebFileSystemImpl::removeRecursively(const WebString& path,
+void WebFileSystemImpl::removeRecursively(const WebURL& path,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
ChildThread::current()->file_system_dispatcher();
@@ -60,7 +62,7 @@ void WebFileSystemImpl::removeRecursively(const WebString& path,
new WebFileSystemCallbackDispatcher(callbacks));
}
-void WebFileSystemImpl::readMetadata(const WebString& path,
+void WebFileSystemImpl::readMetadata(const WebURL& path,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
ChildThread::current()->file_system_dispatcher();
@@ -68,7 +70,7 @@ void WebFileSystemImpl::readMetadata(const WebString& path,
new WebFileSystemCallbackDispatcher(callbacks));
}
-void WebFileSystemImpl::createFile(const WebString& path,
+void WebFileSystemImpl::createFile(const WebURL& path,
bool exclusive,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
@@ -77,7 +79,7 @@ void WebFileSystemImpl::createFile(const WebString& path,
false, new WebFileSystemCallbackDispatcher(callbacks));
}
-void WebFileSystemImpl::createDirectory(const WebString& path,
+void WebFileSystemImpl::createDirectory(const WebURL& path,
bool exclusive,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
@@ -86,7 +88,7 @@ void WebFileSystemImpl::createDirectory(const WebString& path,
false, new WebFileSystemCallbackDispatcher(callbacks));
}
-void WebFileSystemImpl::fileExists(const WebString& path,
+void WebFileSystemImpl::fileExists(const WebURL& path,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
ChildThread::current()->file_system_dispatcher();
@@ -94,7 +96,7 @@ void WebFileSystemImpl::fileExists(const WebString& path,
new WebFileSystemCallbackDispatcher(callbacks));
}
-void WebFileSystemImpl::directoryExists(const WebString& path,
+void WebFileSystemImpl::directoryExists(const WebURL& path,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
ChildThread::current()->file_system_dispatcher();
@@ -102,7 +104,7 @@ void WebFileSystemImpl::directoryExists(const WebString& path,
new WebFileSystemCallbackDispatcher(callbacks));
}
-void WebFileSystemImpl::readDirectory(const WebString& path,
+void WebFileSystemImpl::readDirectory(const WebURL& path,
WebFileSystemCallbacks* callbacks) {
FileSystemDispatcher* dispatcher =
ChildThread::current()->file_system_dispatcher();
@@ -111,6 +113,67 @@ void WebFileSystemImpl::readDirectory(const WebString& path,
}
WebKit::WebFileWriter* WebFileSystemImpl::createFileWriter(
- const WebString& path, WebKit::WebFileWriterClient* client) {
+ const WebURL& path, WebKit::WebFileWriterClient* client) {
return new WebFileWriterImpl(GURL(path), client);
}
+
+// These are temporary shims to link up the old calls to the new implementation.
+// They'll go away as soon as the webkit side gets updated.
+void WebFileSystemImpl::move(const WebString& src_path,
+ const WebString& dest_path,
+ WebFileSystemCallbacks* callbacks) {
+ move(GURL(src_path), GURL(dest_path), callbacks);
+}
+
+void WebFileSystemImpl::copy(const WebString& src_path,
+ const WebString& dest_path,
+ WebFileSystemCallbacks* callbacks) {
+ copy(GURL(src_path), GURL(dest_path), callbacks);
+}
+
+void WebFileSystemImpl::remove(const WebString& path,
+ WebFileSystemCallbacks* callbacks) {
+ remove(GURL(path), callbacks);
+}
+
+void WebFileSystemImpl::removeRecursively(const WebString& path,
+ WebFileSystemCallbacks* callbacks) {
+ removeRecursively(GURL(path), callbacks);
+}
+
+void WebFileSystemImpl::readMetadata(const WebString& path,
+ WebFileSystemCallbacks* callbacks) {
+ readMetadata(GURL(path), callbacks);
+}
+
+void WebFileSystemImpl::createFile(const WebString& path,
+ bool exclusive,
+ WebFileSystemCallbacks* callbacks) {
+ createFile(GURL(path), exclusive, callbacks);
+}
+
+void WebFileSystemImpl::createDirectory(const WebString& path,
+ bool exclusive,
+ WebFileSystemCallbacks* callbacks) {
+ createDirectory(GURL(path), exclusive, callbacks);
+}
+
+void WebFileSystemImpl::fileExists(const WebString& path,
+ WebFileSystemCallbacks* callbacks) {
+ fileExists(GURL(path), callbacks);
+}
+
+void WebFileSystemImpl::directoryExists(const WebString& path,
+ WebFileSystemCallbacks* callbacks) {
+ directoryExists(GURL(path), callbacks);
+}
+
+void WebFileSystemImpl::readDirectory(const WebString& path,
+ WebFileSystemCallbacks* callbacks) {
+ readDirectory(GURL(path), callbacks);
+}
+
+WebKit::WebFileWriter* WebFileSystemImpl::createFileWriter(
+ const WebString& path, WebKit::WebFileWriterClient* client) {
+ return createFileWriter(GURL(path), client);
+}
« no previous file with comments | « content/common/file_system/webfilesystem_impl.h ('k') | webkit/fileapi/file_system_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698