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

Unified Diff: chrome/browser/dom_ui/plugins_ui.cc

Issue 5699005: Policy: Re-enabled plugin still disabled (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Cleaned up WebPluginInfo and rebased on fixed PluginGroup::InitFrom. Created 10 years 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/browser/dom_ui/plugins_ui.cc
diff --git a/chrome/browser/dom_ui/plugins_ui.cc b/chrome/browser/dom_ui/plugins_ui.cc
index aaf59f12eefd6311798c875d00130be53542c555..e4918e93d37ab254f92a6f2ba03863e546b44b6a 100644
--- a/chrome/browser/dom_ui/plugins_ui.cc
+++ b/chrome/browser/dom_ui/plugins_ui.cc
@@ -205,12 +205,12 @@ void PluginsDOMHandler::HandleRequestPluginsData(const ListValue* args) {
void PluginsDOMHandler::HandleEnablePluginMessage(const ListValue* args) {
// Be robust in accepting badness since plug-ins display HTML (hence
// JavaScript).
- if (args->GetSize() != 3)
+ if (args->GetSize() != 4)
return;
std::string enable_str;
std::string is_group_str;
- if (!args->GetString(1, &enable_str) || !args->GetString(2, &is_group_str))
+ if (!args->GetString(2, &enable_str) || !args->GetString(3, &is_group_str))
return;
bool enable = enable_str == "true";
@@ -233,11 +233,12 @@ void PluginsDOMHandler::HandleEnablePluginMessage(const ListValue* args) {
}
}
} else {
+ string16 name;
FilePath::StringType file_path;
- if (!args->GetString(0, &file_path))
+ if (!args->GetString(0, &file_path) || !args->GetString(1, &name))
return;
- plugin_updater->EnablePluginFile(enable, file_path);
+ plugin_updater->EnablePlugin(enable, file_path, name);
}
// TODO(viettrungluu): We might also want to ensure that the plugins

Powered by Google App Engine
This is Rietveld 408576698