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

Unified Diff: chrome/browser/automation/testing_automation_provider.cc

Issue 7848025: Store plug-in enabled/disabled state in PluginPrefs instead of WebPluginInfo. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: copyright Created 9 years, 3 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
« no previous file with comments | « no previous file | chrome/browser/component_updater/pepper_flash_component_installer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/automation/testing_automation_provider.cc
diff --git a/chrome/browser/automation/testing_automation_provider.cc b/chrome/browser/automation/testing_automation_provider.cc
index 4ad0a905c3cb0430f238a2b5d880f17986a06885..c3d2fd9dc257678dcc8c5814bb91bbffb1f3946d 100644
--- a/chrome/browser/automation/testing_automation_provider.cc
+++ b/chrome/browser/automation/testing_automation_provider.cc
@@ -3536,12 +3536,9 @@ void TestingAutomationProvider::EnablePlugin(Browser* browser,
if (!args->GetString("path", &path)) {
reply.SendError("path not specified.");
return;
- } else if (!webkit::npapi::PluginList::Singleton()->EnablePlugin(
- FilePath(path))) {
- reply.SendError(StringPrintf("Could not enable plugin for path %s.",
- path.c_str()));
- return;
}
+ PluginPrefs::GetForProfile(browser->profile())->EnablePlugin(
+ true, FilePath(path));
reply.SendSuccess(NULL);
}
@@ -3556,12 +3553,9 @@ void TestingAutomationProvider::DisablePlugin(Browser* browser,
if (!args->GetString("path", &path)) {
reply.SendError("path not specified.");
return;
- } else if (!webkit::npapi::PluginList::Singleton()->DisablePlugin(
- FilePath(path))) {
- reply.SendError(StringPrintf("Could not disable plugin for path %s.",
- path.c_str()));
- return;
}
+ PluginPrefs::GetForProfile(browser->profile())->EnablePlugin(
+ false, FilePath(path));
reply.SendSuccess(NULL);
}
« no previous file with comments | « no previous file | chrome/browser/component_updater/pepper_flash_component_installer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698