Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5921)

Unified Diff: chrome/renderer/chrome_content_renderer_client.cc

Issue 11052019: <browser> Make new implementation the default. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix browsertests for browser plugin. Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/renderer/chrome_content_renderer_client.cc
diff --git a/chrome/renderer/chrome_content_renderer_client.cc b/chrome/renderer/chrome_content_renderer_client.cc
index bbd8208a5bd5a4b4b7703ebcdf35de9fdb91784f..9d31945c2d1698240c7bb01e8e02a132c7d8d418 100644
--- a/chrome/renderer/chrome_content_renderer_client.cc
+++ b/chrome/renderer/chrome_content_renderer_client.cc
@@ -307,11 +307,19 @@ bool ChromeContentRendererClient::OverrideCreatePlugin(
const WebPluginParams& params,
WebPlugin** plugin) {
std::string orig_mime_type = params.mimeType.utf8();
- if (orig_mime_type == content::kBrowserPluginNewMimeType ||
- ((orig_mime_type == content::kBrowserPluginMimeType) &&
+ if (orig_mime_type == content::kBrowserPluginMimeType) {
+ bool browser_plugin_old_impl = CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kEnableBrowserPluginOldImplementation);
+ if (!browser_plugin_old_impl) {
+ // TODO(lazyboy): Restrict new path to apps as well?
Mihai Parparita -not on Chrome 2012/10/03 22:44:00 Please do.
lazyboy 2012/10/03 23:26:57 Done. Also the other TODO below should be covered
+ return false;
+ } else if (browser_plugin_old_impl &&
extensions::ExtensionHelper::Get(render_view)->view_type() ==
- VIEW_TYPE_APP_SHELL)) {
+ VIEW_TYPE_APP_SHELL) {
+ // TODO(fsamuel): Remove this once upstreaming of the new browser plugin
+ // is complete.
return false;
+ }
}
ChromeViewHostMsg_GetPluginInfo_Output output;

Powered by Google App Engine
This is Rietveld 408576698