| 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 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 266 // | 266 // |
| 267 // Child processes that have different storage partition identifiers will | 267 // Child processes that have different storage partition identifiers will |
| 268 // behave as if they belong to different web browsers and not be able to | 268 // behave as if they belong to different web browsers and not be able to |
| 269 // access each other's cookies, local storage, etc. IDs must only fit the | 269 // access each other's cookies, local storage, etc. IDs must only fit the |
| 270 // pattern [a-z0-9]* (lowercase letters or digits). | 270 // pattern [a-z0-9]* (lowercase letters or digits). |
| 271 // | 271 // |
| 272 // Returns the empty string for the regular storage partition. | 272 // Returns the empty string for the regular storage partition. |
| 273 virtual std::string GetStoragePartitionIdForChildProcess( | 273 virtual std::string GetStoragePartitionIdForChildProcess( |
| 274 content::BrowserContext* browser_context, | 274 content::BrowserContext* browser_context, |
| 275 int child_process_id); | 275 int child_process_id); |
| 276 virtual std::string GetStoragePartitionIdForSiteInstance( |
| 277 content::BrowserContext* browser_context, |
| 278 content::SiteInstance* instance); |
| 279 |
| 280 // Allows the embedder to provide a validation check for |partition_id|s. |
| 281 // This domain of valid entries should match the range of outputs for |
| 282 // GetStoragePartitionIdForChildProcess(). |
| 283 virtual bool IsValidStoragePartitionId(BrowserContext* browser_context, |
| 284 const std::string& partition_id); |
| 276 | 285 |
| 277 // Create and return a new quota permission context. | 286 // Create and return a new quota permission context. |
| 278 virtual QuotaPermissionContext* CreateQuotaPermissionContext(); | 287 virtual QuotaPermissionContext* CreateQuotaPermissionContext(); |
| 279 | 288 |
| 280 // Open the given file in the desktop's default manner. | 289 // Open the given file in the desktop's default manner. |
| 281 virtual void OpenItem(const FilePath& path) {} | 290 virtual void OpenItem(const FilePath& path) {} |
| 282 | 291 |
| 283 // Show the given file in a file manager. If possible, select the file. | 292 // Show the given file in a file manager. If possible, select the file. |
| 284 virtual void ShowItemInFolder(const FilePath& path) {} | 293 virtual void ShowItemInFolder(const FilePath& path) {} |
| 285 | 294 |
| (...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 446 // This is called on a worker thread. | 455 // This is called on a worker thread. |
| 447 virtual | 456 virtual |
| 448 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( | 457 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( |
| 449 const GURL& url); | 458 const GURL& url); |
| 450 #endif | 459 #endif |
| 451 }; | 460 }; |
| 452 | 461 |
| 453 } // namespace content | 462 } // namespace content |
| 454 | 463 |
| 455 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 464 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| OLD | NEW |