| 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 <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 237 // that is allowed to commit. | 237 // that is allowed to commit. |
| 238 // This is called on the IO thread. | 238 // This is called on the IO thread. |
| 239 virtual bool IsIllegalOrigin(ResourceContext* resource_context, | 239 virtual bool IsIllegalOrigin(ResourceContext* resource_context, |
| 240 int child_process_id, | 240 int child_process_id, |
| 241 const GURL& origin); | 241 const GURL& origin); |
| 242 | 242 |
| 243 // Returns whether a URL should be allowed to open from a specific context. | 243 // Returns whether a URL should be allowed to open from a specific context. |
| 244 // This also applies in cases where the new URL will open in another process. | 244 // This also applies in cases where the new URL will open in another process. |
| 245 virtual bool ShouldAllowOpenURL(SiteInstance* site_instance, const GURL& url); | 245 virtual bool ShouldAllowOpenURL(SiteInstance* site_instance, const GURL& url); |
| 246 | 246 |
| 247 // Allows the embedder to override OpenURLParams. |
| 248 virtual void OverrideOpenURLParams(SiteInstance* site_instance, |
| 249 OpenURLParams* params) {} |
| 250 |
| 247 // Returns whether a new view for a given |site_url| can be launched in a | 251 // Returns whether a new view for a given |site_url| can be launched in a |
| 248 // given |process_host|. | 252 // given |process_host|. |
| 249 virtual bool IsSuitableHost(RenderProcessHost* process_host, | 253 virtual bool IsSuitableHost(RenderProcessHost* process_host, |
| 250 const GURL& site_url); | 254 const GURL& site_url); |
| 251 | 255 |
| 252 // Returns whether a new view for a new site instance can be added to a | 256 // Returns whether a new view for a new site instance can be added to a |
| 253 // given |process_host|. | 257 // given |process_host|. |
| 254 virtual bool MayReuseHost(RenderProcessHost* process_host); | 258 virtual bool MayReuseHost(RenderProcessHost* process_host); |
| 255 | 259 |
| 256 // Returns whether a new process should be created or an existing one should | 260 // Returns whether a new process should be created or an existing one should |
| (...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 779 // Allows an embedder to provide its own ExternalVideoSurfaceContainer | 783 // Allows an embedder to provide its own ExternalVideoSurfaceContainer |
| 780 // implementation. Return nullptr to disable external surface video. | 784 // implementation. Return nullptr to disable external surface video. |
| 781 virtual ExternalVideoSurfaceContainer* | 785 virtual ExternalVideoSurfaceContainer* |
| 782 OverrideCreateExternalVideoSurfaceContainer(WebContents* web_contents); | 786 OverrideCreateExternalVideoSurfaceContainer(WebContents* web_contents); |
| 783 #endif | 787 #endif |
| 784 }; | 788 }; |
| 785 | 789 |
| 786 } // namespace content | 790 } // namespace content |
| 787 | 791 |
| 788 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 792 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| OLD | NEW |