| 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 "webkit/tools/test_shell/test_shell_request_context.h" | 5 #include "webkit/tools/test_shell/test_shell_request_context.h" |
| 6 | 6 |
| 7 #include "build/build_config.h" | 7 #include "build/build_config.h" |
| 8 | 8 |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 WebKit::webKitPlatformSupport()->fileSystem())->file_system_context(); | 120 WebKit::webKitPlatformSupport()->fileSystem())->file_system_context(); |
| 121 | 121 |
| 122 net::URLRequestJobFactory* job_factory = new net::URLRequestJobFactory; | 122 net::URLRequestJobFactory* job_factory = new net::URLRequestJobFactory; |
| 123 job_factory->SetProtocolHandler( | 123 job_factory->SetProtocolHandler( |
| 124 "blob", | 124 "blob", |
| 125 new webkit_blob::BlobProtocolHandler( | 125 new webkit_blob::BlobProtocolHandler( |
| 126 blob_storage_controller_.get(), | 126 blob_storage_controller_.get(), |
| 127 SimpleResourceLoaderBridge::GetIoThread())); | 127 SimpleResourceLoaderBridge::GetIoThread())); |
| 128 job_factory->SetProtocolHandler( | 128 job_factory->SetProtocolHandler( |
| 129 "filesystem", | 129 "filesystem", |
| 130 fileapi::CreateFileSystemProtocolHandler( | 130 fileapi::CreateFileSystemProtocolHandler(file_system_context_.get())); |
| 131 file_system_context_.get(), | |
| 132 SimpleResourceLoaderBridge::GetIoThread())); | |
| 133 storage_.set_job_factory(job_factory); | 131 storage_.set_job_factory(job_factory); |
| 134 } | 132 } |
| 135 | 133 |
| 136 TestShellRequestContext::~TestShellRequestContext() { | 134 TestShellRequestContext::~TestShellRequestContext() { |
| 137 } | 135 } |
| 138 | 136 |
| 139 const std::string& TestShellRequestContext::GetUserAgent( | 137 const std::string& TestShellRequestContext::GetUserAgent( |
| 140 const GURL& url) const { | 138 const GURL& url) const { |
| 141 return webkit_glue::GetUserAgent(url); | 139 return webkit_glue::GetUserAgent(url); |
| 142 } | 140 } |
| OLD | NEW |