OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/layout_test/layout_test_content_browser_client.h
" | 5 #include "content/shell/browser/layout_test/layout_test_content_browser_client.h
" |
6 | 6 |
7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
8 #include "content/public/browser/browser_context.h" | 8 #include "content/public/browser/browser_context.h" |
9 #include "content/public/browser/browser_thread.h" | 9 #include "content/public/browser/browser_thread.h" |
10 #include "content/public/browser/render_process_host.h" | 10 #include "content/public/browser/render_process_host.h" |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
121 switches::kEnableLeakDetection)); | 121 switches::kEnableLeakDetection)); |
122 } | 122 } |
123 } | 123 } |
124 | 124 |
125 BrowserMainParts* LayoutTestContentBrowserClient::CreateBrowserMainParts( | 125 BrowserMainParts* LayoutTestContentBrowserClient::CreateBrowserMainParts( |
126 const MainFunctionParams& parameters) { | 126 const MainFunctionParams& parameters) { |
127 set_browser_main_parts(new LayoutTestBrowserMainParts(parameters)); | 127 set_browser_main_parts(new LayoutTestBrowserMainParts(parameters)); |
128 return shell_browser_main_parts(); | 128 return shell_browser_main_parts(); |
129 } | 129 } |
130 | 130 |
| 131 void LayoutTestContentBrowserClient::GetTemporaryStorageConfiguration( |
| 132 BrowserContext* context, |
| 133 const base::FilePath& partition_path, bool is_incognito, |
| 134 const storage::TemporaryStorageConfigurationCallback& callback) { |
| 135 // Default quota for each origin is 5MB. |
| 136 const int kDefaultLayoutTestQuotaBytes = 5 * 1024 * 1024; |
| 137 storage::TemporaryStorageConfiguration config; |
| 138 config.per_host_quota = kDefaultLayoutTestQuotaBytes; |
| 139 config.pool_size = 5 * kDefaultLayoutTestQuotaBytes; |
| 140 config.must_remain_available = kDefaultLayoutTestQuotaBytes; |
| 141 config.refresh_interval = base::TimeDelta::Max(); |
| 142 callback.Run(config); |
| 143 } |
| 144 |
131 PlatformNotificationService* | 145 PlatformNotificationService* |
132 LayoutTestContentBrowserClient::GetPlatformNotificationService() { | 146 LayoutTestContentBrowserClient::GetPlatformNotificationService() { |
133 return layout_test_notification_manager_.get(); | 147 return layout_test_notification_manager_.get(); |
134 } | 148 } |
135 | 149 |
136 } // namespace content | 150 } // namespace content |
OLD | NEW |