| 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 #include "chrome/browser/chrome_content_browser_client.h" | 5 #include "chrome/browser/chrome_content_browser_client.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "chrome/app/breakpad_mac.h" | 8 #include "chrome/app/breakpad_mac.h" |
| 9 #include "chrome/browser/browser_about_handler.h" | 9 #include "chrome/browser/browser_about_handler.h" |
| 10 #include "chrome/browser/browser_process.h" | 10 #include "chrome/browser/browser_process.h" |
| (...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 160 | 160 |
| 161 return true; | 161 return true; |
| 162 } | 162 } |
| 163 | 163 |
| 164 } // namespace | 164 } // namespace |
| 165 | 165 |
| 166 namespace chrome { | 166 namespace chrome { |
| 167 | 167 |
| 168 void ChromeContentBrowserClient::RenderViewHostCreated( | 168 void ChromeContentBrowserClient::RenderViewHostCreated( |
| 169 RenderViewHost* render_view_host) { | 169 RenderViewHost* render_view_host) { |
| 170 new ChromeRenderViewHostObserver(render_view_host); | 170 |
| 171 SiteInstance* site_instance = render_view_host->site_instance(); |
| 172 Profile* profile = Profile::FromBrowserContext( |
| 173 site_instance->browsing_instance()->browser_context()); |
| 174 |
| 175 new ChromeRenderViewHostObserver(render_view_host, |
| 176 profile->GetNetworkPredictor()); |
| 171 new DevToolsHandler(render_view_host); | 177 new DevToolsHandler(render_view_host); |
| 172 new ExtensionMessageHandler(render_view_host); | 178 new ExtensionMessageHandler(render_view_host); |
| 173 | 179 |
| 174 InitRenderViewHostForExtensions(render_view_host); | 180 InitRenderViewHostForExtensions(render_view_host); |
| 175 } | 181 } |
| 176 | 182 |
| 177 void ChromeContentBrowserClient::BrowserRenderProcessHostCreated( | 183 void ChromeContentBrowserClient::BrowserRenderProcessHostCreated( |
| 178 BrowserRenderProcessHost* host) { | 184 BrowserRenderProcessHost* host) { |
| 179 int id = host->id(); | 185 int id = host->id(); |
| 180 Profile* profile = Profile::FromBrowserContext(host->browser_context()); | 186 Profile* profile = Profile::FromBrowserContext(host->browser_context()); |
| (...skipping 604 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 785 #if defined(USE_NSS) | 791 #if defined(USE_NSS) |
| 786 crypto::CryptoModuleBlockingPasswordDelegate* | 792 crypto::CryptoModuleBlockingPasswordDelegate* |
| 787 ChromeContentBrowserClient::GetCryptoPasswordDelegate( | 793 ChromeContentBrowserClient::GetCryptoPasswordDelegate( |
| 788 const GURL& url) { | 794 const GURL& url) { |
| 789 return browser::NewCryptoModuleBlockingDialogDelegate( | 795 return browser::NewCryptoModuleBlockingDialogDelegate( |
| 790 browser::kCryptoModulePasswordKeygen, url.host()); | 796 browser::kCryptoModulePasswordKeygen, url.host()); |
| 791 } | 797 } |
| 792 #endif | 798 #endif |
| 793 | 799 |
| 794 } // namespace chrome | 800 } // namespace chrome |
| OLD | NEW |