| 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 #ifndef CONTENT_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 5 #ifndef CONTENT_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| 6 #define CONTENT_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 6 #define CONTENT_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 class NetLog; | 42 class NetLog; |
| 43 class URLRequest; | 43 class URLRequest; |
| 44 class URLRequestContext; | 44 class URLRequestContext; |
| 45 class X509Certificate; | 45 class X509Certificate; |
| 46 } | 46 } |
| 47 | 47 |
| 48 namespace ui { | 48 namespace ui { |
| 49 class Clipboard; | 49 class Clipboard; |
| 50 } | 50 } |
| 51 | 51 |
| 52 namespace webkit { |
| 53 namespace npapi { |
| 54 struct WebPluginInfo; |
| 55 } |
| 56 } |
| 57 |
| 52 namespace content { | 58 namespace content { |
| 53 | 59 |
| 54 class BrowserContext; | 60 class BrowserContext; |
| 61 class PluginFilter; |
| 55 class ResourceContext; | 62 class ResourceContext; |
| 56 class WebUIFactory; | 63 class WebUIFactory; |
| 57 | 64 |
| 58 // Embedder API (or SPI) for participating in browser logic, to be implemented | 65 // Embedder API (or SPI) for participating in browser logic, to be implemented |
| 59 // by the client of the content browser. See ChromeContentBrowserClient for the | 66 // by the client of the content browser. See ChromeContentBrowserClient for the |
| 60 // principal implementation. The methods are assumed to be called on the UI | 67 // principal implementation. The methods are assumed to be called on the UI |
| 61 // thread unless otherwise specified. Use this "escape hatch" sparingly, to | 68 // thread unless otherwise specified. Use this "escape hatch" sparingly, to |
| 62 // avoid the embedder interface ballooning and becoming very specific to Chrome. | 69 // avoid the embedder interface ballooning and becoming very specific to Chrome. |
| 63 // (Often, the call out to the client can happen in a different part of the code | 70 // (Often, the call out to the client can happen in a different part of the code |
| 64 // that either already has a hook out to the embedder, or calls out to one of | 71 // that either already has a hook out to the embedder, or calls out to one of |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 const std::string& cookie_line, | 148 const std::string& cookie_line, |
| 142 const content::ResourceContext& context, | 149 const content::ResourceContext& context, |
| 143 int render_process_id, | 150 int render_process_id, |
| 144 int render_view_id, | 151 int render_view_id, |
| 145 net::CookieOptions* options) = 0; | 152 net::CookieOptions* options) = 0; |
| 146 | 153 |
| 147 // This is called on the IO thread. | 154 // This is called on the IO thread. |
| 148 virtual bool AllowSaveLocalState( | 155 virtual bool AllowSaveLocalState( |
| 149 const content::ResourceContext& context) = 0; | 156 const content::ResourceContext& context) = 0; |
| 150 | 157 |
| 158 // Creates a new PluginFilter. |
| 159 // This is called on the IO thread. |
| 160 virtual content::PluginFilter* CreatePluginFilter( |
| 161 int render_process_id, |
| 162 int render_view_id, |
| 163 const content::ResourceContext& resource_context, |
| 164 const GURL& url, |
| 165 const GURL& policy_url) = 0; |
| 166 |
| 151 // Allows the embedder to override the request context based on the URL for | 167 // Allows the embedder to override the request context based on the URL for |
| 152 // certain operations, like cookie access. Returns NULL to indicate the | 168 // certain operations, like cookie access. Returns NULL to indicate the |
| 153 // regular request context should be used. | 169 // regular request context should be used. |
| 154 // This is called on the IO thread. | 170 // This is called on the IO thread. |
| 155 virtual net::URLRequestContext* OverrideRequestContextForURL( | 171 virtual net::URLRequestContext* OverrideRequestContextForURL( |
| 156 const GURL& url, const content::ResourceContext& context) = 0; | 172 const GURL& url, const content::ResourceContext& context) = 0; |
| 157 | 173 |
| 158 // Create and return a new quota permission context. | 174 // Create and return a new quota permission context. |
| 159 virtual QuotaPermissionContext* CreateQuotaPermissionContext() = 0; | 175 virtual QuotaPermissionContext* CreateQuotaPermissionContext() = 0; |
| 160 | 176 |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 272 // This is called on a worker thread. | 288 // This is called on a worker thread. |
| 273 virtual | 289 virtual |
| 274 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( | 290 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( |
| 275 const GURL& url) = 0; | 291 const GURL& url) = 0; |
| 276 #endif | 292 #endif |
| 277 }; | 293 }; |
| 278 | 294 |
| 279 } // namespace content | 295 } // namespace content |
| 280 | 296 |
| 281 #endif // CONTENT_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 297 #endif // CONTENT_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| OLD | NEW |