| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/shell/browser/shell_content_browser_client.h" | 5 #include "content/shell/browser/shell_content_browser_client.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/base_switches.h" | 10 #include "base/base_switches.h" |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 #include "content/shell/browser/shell_browser_main_parts.h" | 32 #include "content/shell/browser/shell_browser_main_parts.h" |
| 33 #include "content/shell/browser/shell_devtools_manager_delegate.h" | 33 #include "content/shell/browser/shell_devtools_manager_delegate.h" |
| 34 #include "content/shell/browser/shell_net_log.h" | 34 #include "content/shell/browser/shell_net_log.h" |
| 35 #include "content/shell/browser/shell_quota_permission_context.h" | 35 #include "content/shell/browser/shell_quota_permission_context.h" |
| 36 #include "content/shell/browser/shell_resource_dispatcher_host_delegate.h" | 36 #include "content/shell/browser/shell_resource_dispatcher_host_delegate.h" |
| 37 #include "content/shell/browser/shell_web_contents_view_delegate_creator.h" | 37 #include "content/shell/browser/shell_web_contents_view_delegate_creator.h" |
| 38 #include "content/shell/common/shell_messages.h" | 38 #include "content/shell/common/shell_messages.h" |
| 39 #include "content/shell/common/shell_switches.h" | 39 #include "content/shell/common/shell_switches.h" |
| 40 #include "grit/shell_resources.h" | 40 #include "grit/shell_resources.h" |
| 41 #include "net/url_request/url_request_context_getter.h" | 41 #include "net/url_request/url_request_context_getter.h" |
| 42 #include "storage/browser/quota/quota_settings.h" |
| 42 #include "ui/base/resource/resource_bundle.h" | 43 #include "ui/base/resource/resource_bundle.h" |
| 43 #include "url/gurl.h" | 44 #include "url/gurl.h" |
| 44 #include "url/origin.h" | 45 #include "url/origin.h" |
| 45 | 46 |
| 46 #if defined(OS_ANDROID) | 47 #if defined(OS_ANDROID) |
| 47 #include "base/android/apk_assets.h" | 48 #include "base/android/apk_assets.h" |
| 48 #include "base/android/path_utils.h" | 49 #include "base/android/path_utils.h" |
| 49 #include "components/crash/content/browser/crash_dump_manager_android.h" | 50 #include "components/crash/content/browser/crash_dump_manager_android.h" |
| 50 #include "content/shell/android/shell_descriptors.h" | 51 #include "content/shell/android/shell_descriptors.h" |
| 51 #endif | 52 #endif |
| (...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 272 WebContentsViewDelegate* ShellContentBrowserClient::GetWebContentsViewDelegate( | 273 WebContentsViewDelegate* ShellContentBrowserClient::GetWebContentsViewDelegate( |
| 273 WebContents* web_contents) { | 274 WebContents* web_contents) { |
| 274 return CreateShellWebContentsViewDelegate(web_contents); | 275 return CreateShellWebContentsViewDelegate(web_contents); |
| 275 } | 276 } |
| 276 | 277 |
| 277 QuotaPermissionContext* | 278 QuotaPermissionContext* |
| 278 ShellContentBrowserClient::CreateQuotaPermissionContext() { | 279 ShellContentBrowserClient::CreateQuotaPermissionContext() { |
| 279 return new ShellQuotaPermissionContext(); | 280 return new ShellQuotaPermissionContext(); |
| 280 } | 281 } |
| 281 | 282 |
| 283 void ShellContentBrowserClient::GetQuotaSettings( |
| 284 BrowserContext* context, |
| 285 const base::FilePath& partition_path, |
| 286 bool is_incognito, |
| 287 const storage::OptionalQuotaSettingsCallback& callback) { |
| 288 callback.Run(storage::GetHardCodedSettings(100 * 1024 * 1024)); |
| 289 } |
| 290 |
| 282 void ShellContentBrowserClient::SelectClientCertificate( | 291 void ShellContentBrowserClient::SelectClientCertificate( |
| 283 WebContents* web_contents, | 292 WebContents* web_contents, |
| 284 net::SSLCertRequestInfo* cert_request_info, | 293 net::SSLCertRequestInfo* cert_request_info, |
| 285 std::unique_ptr<ClientCertificateDelegate> delegate) { | 294 std::unique_ptr<ClientCertificateDelegate> delegate) { |
| 286 if (!select_client_certificate_callback_.is_null()) | 295 if (!select_client_certificate_callback_.is_null()) |
| 287 select_client_certificate_callback_.Run(); | 296 select_client_certificate_callback_.Run(); |
| 288 } | 297 } |
| 289 | 298 |
| 290 SpeechRecognitionManagerDelegate* | 299 SpeechRecognitionManagerDelegate* |
| 291 ShellContentBrowserClient::CreateSpeechRecognitionManagerDelegate() { | 300 ShellContentBrowserClient::CreateSpeechRecognitionManagerDelegate() { |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 375 ShellBrowserContext* ShellContentBrowserClient::browser_context() { | 384 ShellBrowserContext* ShellContentBrowserClient::browser_context() { |
| 376 return shell_browser_main_parts_->browser_context(); | 385 return shell_browser_main_parts_->browser_context(); |
| 377 } | 386 } |
| 378 | 387 |
| 379 ShellBrowserContext* | 388 ShellBrowserContext* |
| 380 ShellContentBrowserClient::off_the_record_browser_context() { | 389 ShellContentBrowserClient::off_the_record_browser_context() { |
| 381 return shell_browser_main_parts_->off_the_record_browser_context(); | 390 return shell_browser_main_parts_->off_the_record_browser_context(); |
| 382 } | 391 } |
| 383 | 392 |
| 384 } // namespace content | 393 } // namespace content |
| OLD | NEW |