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 #ifndef CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <utility> | 9 #include <utility> |
10 #include <vector> | 10 #include <vector> |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
232 | 232 |
233 // Allow the embedder to control if access to IndexedDB by a shared worker | 233 // Allow the embedder to control if access to IndexedDB by a shared worker |
234 // is allowed. | 234 // is allowed. |
235 // This is called on the IO thread. | 235 // This is called on the IO thread. |
236 virtual bool AllowWorkerIndexedDB( | 236 virtual bool AllowWorkerIndexedDB( |
237 const GURL& url, | 237 const GURL& url, |
238 const string16& name, | 238 const string16& name, |
239 ResourceContext* context, | 239 ResourceContext* context, |
240 const std::vector<std::pair<int, int> >& render_views); | 240 const std::vector<std::pair<int, int> >& render_views); |
241 | 241 |
242 // Allows the embedder to override the request context based on the URL for | 242 // Allow the embedder to override the request context based on the URL for |
243 // certain operations, like cookie access. Returns NULL to indicate the | 243 // certain operations, like cookie access. Returns NULL to indicate the |
244 // regular request context should be used. | 244 // regular request context should be used. |
245 // This is called on the IO thread. | 245 // This is called on the IO thread. |
246 virtual net::URLRequestContext* OverrideRequestContextForURL( | 246 virtual net::URLRequestContext* OverrideRequestContextForURL( |
247 const GURL& url, ResourceContext* context); | 247 const GURL& url, ResourceContext* context); |
248 | 248 |
| 249 // Allow the embedder to specify storage parititon id associated with a child |
| 250 // process. |
| 251 // |
| 252 // Child processes that have different storage partition identifiers will |
| 253 // behave as if they belong to different web browsers and not be able to |
| 254 // access each other's cookies, local storage, etc. IDs must only fit the |
| 255 // pattern [a-z0-9]* (lowercase letters or digits). |
| 256 // |
| 257 // Returns the empty string for the regular storage partition. |
| 258 virtual std::string GetStoragePartitionIdForChildProcess( |
| 259 content::BrowserContext* browser_context, |
| 260 int child_process_id); |
| 261 |
249 // Create and return a new quota permission context. | 262 // Create and return a new quota permission context. |
250 virtual QuotaPermissionContext* CreateQuotaPermissionContext(); | 263 virtual QuotaPermissionContext* CreateQuotaPermissionContext(); |
251 | 264 |
252 // Open the given file in the desktop's default manner. | 265 // Open the given file in the desktop's default manner. |
253 virtual void OpenItem(const FilePath& path) {} | 266 virtual void OpenItem(const FilePath& path) {} |
254 | 267 |
255 // Show the given file in a file manager. If possible, select the file. | 268 // Show the given file in a file manager. If possible, select the file. |
256 virtual void ShowItemInFolder(const FilePath& path) {} | 269 virtual void ShowItemInFolder(const FilePath& path) {} |
257 | 270 |
258 // Informs the embedder that a certificate error has occured. If | 271 // Informs the embedder that a certificate error has occured. If |
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
418 // This is called on a worker thread. | 431 // This is called on a worker thread. |
419 virtual | 432 virtual |
420 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( | 433 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( |
421 const GURL& url); | 434 const GURL& url); |
422 #endif | 435 #endif |
423 }; | 436 }; |
424 | 437 |
425 } // namespace content | 438 } // namespace content |
426 | 439 |
427 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 440 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
OLD | NEW |