| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/common/fileapi/webfilesystem_impl.h" | 5 #include "content/common/fileapi/webfilesystem_impl.h" |
| 6 | 6 |
| 7 #include "content/common/child_thread.h" | 7 #include "content/common/child_thread.h" |
| 8 #include "content/common/fileapi/file_system_dispatcher.h" | 8 #include "content/common/fileapi/file_system_dispatcher.h" |
| 9 #include "content/common/fileapi/webfilesystem_callback_dispatcher.h" | 9 #include "content/common/fileapi/webfilesystem_callback_dispatcher.h" |
| 10 #include "content/common/fileapi/webfilewriter_impl.h" | 10 #include "content/common/fileapi/webfilewriter_impl.h" |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 dispatcher->ReadDirectory(GURL(path), | 113 dispatcher->ReadDirectory(GURL(path), |
| 114 new WebFileSystemCallbackDispatcher(callbacks)); | 114 new WebFileSystemCallbackDispatcher(callbacks)); |
| 115 } | 115 } |
| 116 | 116 |
| 117 WebKit::WebFileWriter* WebFileSystemImpl::createFileWriter( | 117 WebKit::WebFileWriter* WebFileSystemImpl::createFileWriter( |
| 118 const WebURL& path, WebKit::WebFileWriterClient* client) { | 118 const WebURL& path, WebKit::WebFileWriterClient* client) { |
| 119 return new WebFileWriterImpl(GURL(path), client); | 119 return new WebFileWriterImpl(GURL(path), client); |
| 120 } | 120 } |
| 121 | 121 |
| 122 void WebFileSystemImpl::createSnapshotFileAndReadMetadata( | 122 void WebFileSystemImpl::createSnapshotFileAndReadMetadata( |
| 123 const WebKit::WebURL& path, |
| 124 WebKit::WebFileSystemCallbacks* callbacks) { |
| 125 FileSystemDispatcher* dispatcher = |
| 126 ChildThread::current()->file_system_dispatcher(); |
| 127 dispatcher->CreateSnapshotFile( |
| 128 GURL(path), new WebFileSystemCallbackDispatcher(callbacks)); |
| 129 } |
| 130 |
| 131 // DEPRECATED |
| 132 void WebFileSystemImpl::createSnapshotFileAndReadMetadata( |
| 123 const WebKit::WebURL& blobURL, | 133 const WebKit::WebURL& blobURL, |
| 124 const WebKit::WebURL& path, | 134 const WebKit::WebURL& path, |
| 125 WebKit::WebFileSystemCallbacks* callbacks) { | 135 WebKit::WebFileSystemCallbacks* callbacks) { |
| 126 FileSystemDispatcher* dispatcher = | 136 FileSystemDispatcher* dispatcher = |
| 127 ChildThread::current()->file_system_dispatcher(); | 137 ChildThread::current()->file_system_dispatcher(); |
| 128 dispatcher->CreateSnapshotFile( | 138 dispatcher->CreateSnapshotFile_Deprecated( |
| 129 GURL(blobURL), GURL(path), | 139 GURL(blobURL), GURL(path), |
| 130 new WebFileSystemCallbackDispatcher(callbacks)); | 140 new WebFileSystemCallbackDispatcher(callbacks)); |
| 131 } | 141 } |
| 132 | 142 |
| 133 } // namespace content | 143 } // namespace content |
| OLD | NEW |