| 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 CHROME_BROWSER_CHROME_CONTENT_BROWSER_CLIENT_H_ | 5 #ifndef CHROME_BROWSER_CHROME_CONTENT_BROWSER_CLIENT_H_ |
| 6 #define CHROME_BROWSER_CHROME_CONTENT_BROWSER_CLIENT_H_ | 6 #define CHROME_BROWSER_CHROME_CONTENT_BROWSER_CLIENT_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "content/browser/content_browser_client.h" | 9 #include "content/browser/content_browser_client.h" |
| 10 | 10 |
| 11 namespace chrome { | 11 namespace chrome { |
| 12 | 12 |
| 13 class ChromeContentBrowserClient : public content::ContentBrowserClient { | 13 class ChromeContentBrowserClient : public content::ContentBrowserClient { |
| 14 public: | 14 public: |
| 15 ChromeContentBrowserClient(); |
| 16 ~ChromeContentBrowserClient(); |
| 17 |
| 15 virtual void RenderViewHostCreated(RenderViewHost* render_view_host); | 18 virtual void RenderViewHostCreated(RenderViewHost* render_view_host); |
| 16 virtual void BrowserRenderProcessHostCreated(BrowserRenderProcessHost* host); | 19 virtual void BrowserRenderProcessHostCreated(BrowserRenderProcessHost* host); |
| 17 virtual void PluginProcessHostCreated(PluginProcessHost* host); | 20 virtual void PluginProcessHostCreated(PluginProcessHost* host); |
| 18 virtual void WorkerProcessHostCreated(WorkerProcessHost* host); | 21 virtual void WorkerProcessHostCreated(WorkerProcessHost* host); |
| 19 virtual content::WebUIFactory* GetWebUIFactory(); | 22 virtual content::WebUIFactory* GetWebUIFactory(); |
| 20 virtual GURL GetEffectiveURL(Profile* profile, const GURL& url); | 23 virtual GURL GetEffectiveURL(Profile* profile, const GURL& url); |
| 24 virtual const std::set<std::string>* GetSchemesSameAsAnySiteInstance(); |
| 21 virtual GURL GetAlternateErrorPageURL(const TabContents* tab); | 25 virtual GURL GetAlternateErrorPageURL(const TabContents* tab); |
| 22 virtual std::string GetCanonicalEncodingNameByAliasName( | 26 virtual std::string GetCanonicalEncodingNameByAliasName( |
| 23 const std::string& alias_name); | 27 const std::string& alias_name); |
| 24 virtual void AppendExtraCommandLineSwitches(CommandLine* command_line, | 28 virtual void AppendExtraCommandLineSwitches(CommandLine* command_line, |
| 25 int child_process_id); | 29 int child_process_id); |
| 26 virtual std::string GetApplicationLocale(); | 30 virtual std::string GetApplicationLocale(); |
| 27 virtual bool AllowAppCache(const GURL& manifest_url, | 31 virtual bool AllowAppCache(const GURL& manifest_url, |
| 28 const content::ResourceContext& context); | 32 const content::ResourceContext& context); |
| 29 virtual bool AllowGetCookie(const GURL& url, | 33 virtual bool AllowGetCookie(const GURL& url, |
| 30 const GURL& first_party, | 34 const GURL& first_party, |
| 31 const net::CookieList& cookie_list, | 35 const net::CookieList& cookie_list, |
| 32 const content::ResourceContext& context, | 36 const content::ResourceContext& context, |
| 33 int render_process_id, | 37 int render_process_id, |
| 34 int render_view_id); | 38 int render_view_id); |
| 35 virtual bool AllowSetCookie(const GURL& url, | 39 virtual bool AllowSetCookie(const GURL& url, |
| 36 const GURL& first_party, | 40 const GURL& first_party, |
| 37 const std::string& cookie_line, | 41 const std::string& cookie_line, |
| 38 const content::ResourceContext& context, | 42 const content::ResourceContext& context, |
| 39 int render_process_id, | 43 int render_process_id, |
| 40 int render_view_id, | 44 int render_view_id, |
| 41 net::CookieOptions* options); | 45 net::CookieOptions* options); |
| 42 #if defined(OS_LINUX) | 46 #if defined(OS_LINUX) |
| 43 // Can return an optional fd for crash handling, otherwise returns -1. | 47 // Can return an optional fd for crash handling, otherwise returns -1. |
| 44 virtual int GetCrashSignalFD(const std::string& process_type); | 48 virtual int GetCrashSignalFD(const std::string& process_type); |
| 45 #endif | 49 #endif |
| 50 |
| 51 private: |
| 52 std::set<std::string> schemes_same_as_any_site_instance_; |
| 46 }; | 53 }; |
| 47 | 54 |
| 48 } // namespace chrome | 55 } // namespace chrome |
| 49 | 56 |
| 50 #endif // CHROME_BROWSER_CHROME_CONTENT_BROWSER_CLIENT_H_ | 57 #endif // CHROME_BROWSER_CHROME_CONTENT_BROWSER_CLIENT_H_ |
| OLD | NEW |