| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/browser/mock_content_browser_client.h" | 5 #include "content/browser/mock_content_browser_client.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 } | 43 } |
| 44 | 44 |
| 45 void MockContentBrowserClient::BrowserRenderProcessHostCreated( | 45 void MockContentBrowserClient::BrowserRenderProcessHostCreated( |
| 46 BrowserRenderProcessHost* host) { | 46 BrowserRenderProcessHost* host) { |
| 47 } | 47 } |
| 48 | 48 |
| 49 void MockContentBrowserClient::PluginProcessHostCreated( | 49 void MockContentBrowserClient::PluginProcessHostCreated( |
| 50 PluginProcessHost* host) { | 50 PluginProcessHost* host) { |
| 51 } | 51 } |
| 52 | 52 |
| 53 void MockContentBrowserClient::WorkerProcessHostCreated( | |
| 54 WorkerProcessHost* host) { | |
| 55 } | |
| 56 | |
| 57 WebUIFactory* MockContentBrowserClient::GetWebUIFactory() { | 53 WebUIFactory* MockContentBrowserClient::GetWebUIFactory() { |
| 58 // Return an empty factory so callsites don't have to check for NULL. | 54 // Return an empty factory so callsites don't have to check for NULL. |
| 59 return EmptyWebUIFactory::GetInstance(); | 55 return EmptyWebUIFactory::GetInstance(); |
| 60 } | 56 } |
| 61 | 57 |
| 62 GURL MockContentBrowserClient::GetEffectiveURL( | 58 GURL MockContentBrowserClient::GetEffectiveURL( |
| 63 content::BrowserContext* browser_context, const GURL& url) { | 59 content::BrowserContext* browser_context, const GURL& url) { |
| 64 return GURL(); | 60 return GURL(); |
| 65 } | 61 } |
| 66 | 62 |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 int render_view_id, | 136 int render_view_id, |
| 141 net::CookieOptions* options) { | 137 net::CookieOptions* options) { |
| 142 return true; | 138 return true; |
| 143 } | 139 } |
| 144 | 140 |
| 145 bool MockContentBrowserClient::AllowSaveLocalState( | 141 bool MockContentBrowserClient::AllowSaveLocalState( |
| 146 const content::ResourceContext& context) { | 142 const content::ResourceContext& context) { |
| 147 return true; | 143 return true; |
| 148 } | 144 } |
| 149 | 145 |
| 146 bool MockContentBrowserClient::AllowWorkerDatabase( |
| 147 int worker_route_id, |
| 148 const GURL& url, |
| 149 const string16& name, |
| 150 const string16& display_name, |
| 151 unsigned long estimated_size, |
| 152 WorkerProcessHost* worker_process_host) { |
| 153 return true; |
| 154 } |
| 155 |
| 156 bool MockContentBrowserClient::AllowWorkerFileSystem( |
| 157 int worker_route_id, |
| 158 const GURL& url, |
| 159 WorkerProcessHost* worker_process_host) { |
| 160 return true; |
| 161 } |
| 162 |
| 150 QuotaPermissionContext* | 163 QuotaPermissionContext* |
| 151 MockContentBrowserClient::CreateQuotaPermissionContext() { | 164 MockContentBrowserClient::CreateQuotaPermissionContext() { |
| 152 return NULL; | 165 return NULL; |
| 153 } | 166 } |
| 154 | 167 |
| 155 net::URLRequestContext* MockContentBrowserClient::OverrideRequestContextForURL( | 168 net::URLRequestContext* MockContentBrowserClient::OverrideRequestContextForURL( |
| 156 const GURL& url, const content::ResourceContext& context) { | 169 const GURL& url, const content::ResourceContext& context) { |
| 157 return NULL; | 170 return NULL; |
| 158 } | 171 } |
| 159 | 172 |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 304 #endif | 317 #endif |
| 305 | 318 |
| 306 #if defined(USE_NSS) | 319 #if defined(USE_NSS) |
| 307 crypto::CryptoModuleBlockingPasswordDelegate* | 320 crypto::CryptoModuleBlockingPasswordDelegate* |
| 308 MockContentBrowserClient::GetCryptoPasswordDelegate(const GURL& url) { | 321 MockContentBrowserClient::GetCryptoPasswordDelegate(const GURL& url) { |
| 309 return NULL; | 322 return NULL; |
| 310 } | 323 } |
| 311 #endif | 324 #endif |
| 312 | 325 |
| 313 } // namespace content | 326 } // namespace content |
| OLD | NEW |