| 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);
|
| }
|
|
|
|
|