Chromium Code Reviews| Index: content/test/fake_plugin_service.cc |
| diff --git a/content/test/fake_plugin_service.cc b/content/test/fake_plugin_service.cc |
| index 75e35d4f9c869c7fab1f3d1b17f57709e3a56422..935975071a14e43c10d85305588ae8235c4b5ccc 100644 |
| --- a/content/test/fake_plugin_service.cc |
| +++ b/content/test/fake_plugin_service.cc |
| @@ -4,11 +4,17 @@ |
| #include "content/test/fake_plugin_service.h" |
| +#include "content/public/common/webplugininfo.h" |
| + |
| namespace content { |
| FakePluginService::FakePluginService() { |
| } |
| +FakePluginService::FakePluginService(bool is_plugin_available) |
| + : is_plugin_available_(is_plugin_available) { |
| +} |
| + |
| FakePluginService::~FakePluginService() { |
| } |
| @@ -38,7 +44,11 @@ bool FakePluginService::GetPluginInfo(int render_process_id, |
| WebPluginInfo* info, |
| std::string* actual_mime_type) { |
| *is_stale = false; |
| - return false; |
| + if (!is_plugin_available_) |
| + return false; |
| + info->type = WebPluginInfo::PLUGIN_TYPE_BROWSER_PLUGIN; |
| + info->path = base::FilePath(); |
|
raymes
2015/03/19 00:45:51
If a plugin is available, shouldn't we return a va
Deepak
2015/03/19 10:22:23
Even when we give the proper plugin path then also
|
| + return true; |
|
raymes
2015/03/19 00:45:51
Rather than adding this stuff here, I think we sho
Deepak
2015/03/19 10:22:23
Done.
|
| } |
| bool FakePluginService::GetPluginInfoByPath(const base::FilePath& plugin_path, |