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 #include "chrome/browser/chrome_content_browser_client.h" | 5 #include "chrome/browser/chrome_content_browser_client.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 864 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
875 if (!guest) { | 875 if (!guest) { |
876 // It's ok to return here, since we could be running a browser plugin | 876 // It's ok to return here, since we could be running a browser plugin |
877 // outside an extension, and don't need to attach a | 877 // outside an extension, and don't need to attach a |
878 // BrowserPluginGuestDelegate in that case; | 878 // BrowserPluginGuestDelegate in that case; |
879 // e.g. running with flag --enable-browser-plugin-for-all-view-types. | 879 // e.g. running with flag --enable-browser-plugin-for-all-view-types. |
880 return; | 880 return; |
881 } | 881 } |
882 guest->Attach(embedder_web_contents, extra_params); | 882 guest->Attach(embedder_web_contents, extra_params); |
883 } | 883 } |
884 | 884 |
885 void ChromeContentBrowserClient::RenderProcessHostCreated( | 885 void ChromeContentBrowserClient::RenderProcessWillLaunch( |
886 content::RenderProcessHost* host) { | 886 content::RenderProcessHost* host) { |
887 int id = host->GetID(); | 887 int id = host->GetID(); |
888 Profile* profile = Profile::FromBrowserContext(host->GetBrowserContext()); | 888 Profile* profile = Profile::FromBrowserContext(host->GetBrowserContext()); |
889 net::URLRequestContextGetter* context = | 889 net::URLRequestContextGetter* context = |
890 profile->GetRequestContextForRenderProcess(id); | 890 profile->GetRequestContextForRenderProcess(id); |
891 | 891 |
892 host->AddFilter(new ChromeRenderMessageFilter(id, profile, context)); | 892 host->AddFilter(new ChromeRenderMessageFilter(id, profile, context)); |
893 #if defined(ENABLE_PLUGINS) | 893 #if defined(ENABLE_PLUGINS) |
894 host->AddFilter(new PluginInfoMessageFilter(id, profile)); | 894 host->AddFilter(new PluginInfoMessageFilter(id, profile)); |
895 #endif | 895 #endif |
(...skipping 1745 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2641 | 2641 |
2642 chrome::VersionInfo::Channel channel = chrome::VersionInfo::GetChannel(); | 2642 chrome::VersionInfo::Channel channel = chrome::VersionInfo::GetChannel(); |
2643 return channel <= chrome::VersionInfo::CHANNEL_DEV; | 2643 return channel <= chrome::VersionInfo::CHANNEL_DEV; |
2644 #else | 2644 #else |
2645 return false; | 2645 return false; |
2646 #endif | 2646 #endif |
2647 } | 2647 } |
2648 | 2648 |
2649 | 2649 |
2650 } // namespace chrome | 2650 } // namespace chrome |
OLD | NEW |