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

Unified Diff: webkit/tools/test_shell/simple_file_writer.h

Issue 11416382: ********** Content tests with blob hacking. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 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/tools/test_shell/simple_file_system.cc ('k') | webkit/tools/test_shell/simple_file_writer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/tools/test_shell/simple_file_writer.h
===================================================================
--- webkit/tools/test_shell/simple_file_writer.h (revision 186525)
+++ webkit/tools/test_shell/simple_file_writer.h (working copy)
@@ -9,14 +9,17 @@
#include "base/memory/weak_ptr.h"
#include "webkit/fileapi/webfilewriter_base.h"
-namespace net {
-class URLRequestContext;
-} // namespace net
-
namespace fileapi {
class FileSystemContext;
}
+namespace net {
+class URLRequestContext;
+}
+namespace webkit_blob {
+class BlobStorageContext;
+}
+
// An implementation of WebFileWriter for use in test_shell and DRT.
class SimpleFileWriter : public fileapi::WebFileWriterBase,
public base::SupportsWeakPtr<SimpleFileWriter> {
@@ -29,17 +32,20 @@
// Called by SimpleResourceLoaderBridge when the context is
// created and destroyed.
- static void InitializeOnIOThread(net::URLRequestContext* request_context) {
+ static void InitializeOnIOThread(net::URLRequestContext* request_context,
+ webkit_blob::BlobStorageContext* bsc) {
request_context_ = request_context;
+ blob_storage_context_ = bsc;
}
static void CleanupOnIOThread() {
request_context_ = NULL;
+ blob_storage_context_ = NULL;
}
protected:
// WebFileWriterBase overrides
virtual void DoTruncate(const GURL& path, int64 offset) OVERRIDE;
- virtual void DoWrite(const GURL& path, const GURL& blob_url,
+ virtual void DoWrite(const GURL& path, const std::string& blob_uuid,
int64 offset) OVERRIDE;
virtual void DoCancel() OVERRIDE;
@@ -48,6 +54,7 @@
scoped_refptr<fileapi::FileSystemContext> file_system_context_;
scoped_refptr<IOThreadProxy> io_thread_proxy_;
static net::URLRequestContext* request_context_;
+ static webkit_blob::BlobStorageContext* blob_storage_context_;
};
#endif // WEBKIT_TOOLS_TEST_SHELL_SIMPLE_FILE_WRITER_H_
« no previous file with comments | « webkit/tools/test_shell/simple_file_system.cc ('k') | webkit/tools/test_shell/simple_file_writer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698