| Index: content/browser/plugin_service_impl.cc
|
| diff --git a/content/browser/plugin_service_impl.cc b/content/browser/plugin_service_impl.cc
|
| index 5a79f7dcc845e43f15a74ca7e3b6a4bcd7b0eb06..5abe9e7b6d9a7528612173ed28e00d0932766892 100644
|
| --- a/content/browser/plugin_service_impl.cc
|
| +++ b/content/browser/plugin_service_impl.cc
|
| @@ -658,7 +658,7 @@ void PluginServiceImpl::RegisterPepperPlugins() {
|
| PepperPluginInfo* PluginServiceImpl::GetRegisteredPpapiPluginInfo(
|
| const base::FilePath& plugin_path) {
|
| PepperPluginInfo* info = NULL;
|
| - for (size_t i = 0; i < ppapi_plugins_.size(); i++) {
|
| + for (size_t i = 0; i < ppapi_plugins_.size(); ++i) {
|
| if (ppapi_plugins_[i].path == plugin_path) {
|
| info = &ppapi_plugins_[i];
|
| break;
|
| @@ -681,6 +681,20 @@ PepperPluginInfo* PluginServiceImpl::GetRegisteredPpapiPluginInfo(
|
| return &ppapi_plugins_[ppapi_plugins_.size() - 1];
|
| }
|
|
|
| +bool PluginServiceImpl::IsPepperPluginRegisteredForMimeType(
|
| + const std::string& mime_type) {
|
| + for (size_t i = 0; i < ppapi_plugins_.size(); ++i) {
|
| + const std::vector<WebPluginMimeType>& mime_types =
|
| + ppapi_plugins_[i].mime_types;
|
| + for (size_t j = 0; j < mime_types.size(); ++j) {
|
| + if (mime_types[j].mime_type == mime_type)
|
| + return true;
|
| + }
|
| + }
|
| +
|
| + return false;
|
| +}
|
| +
|
| #if defined(OS_POSIX) && !defined(OS_OPENBSD) && !defined(OS_ANDROID)
|
| // static
|
| void PluginServiceImpl::RegisterFilePathWatcher(FilePathWatcher* watcher,
|
|
|