| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_COMMON_PEPPER_PLUGIN_REGISTRY_H_ | 5 #ifndef CHROME_COMMON_PEPPER_PLUGIN_REGISTRY_H_ |
| 6 #define CHROME_COMMON_PEPPER_PLUGIN_REGISTRY_H_ | 6 #define CHROME_COMMON_PEPPER_PLUGIN_REGISTRY_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <vector> | 10 #include <vector> |
| 11 | 11 |
| 12 #include "webkit/glue/plugins/pepper_plugin_module.h" | 12 #include "webkit/glue/plugins/pepper_plugin_module.h" |
| 13 | 13 |
| 14 struct PepperPluginInfo { | 14 struct PepperPluginInfo { |
| 15 FilePath path; // Internal plugins are of the form "internal-[name]". | 15 FilePath path; // Internal plugins are of the form "internal-[name]". |
| 16 std::vector<std::string> mime_types; | 16 std::vector<std::string> mime_types; |
| 17 std::string name; | 17 std::string name; |
| 18 std::string description; | 18 std::string description; |
| 19 std::string file_extensions; |
| 20 std::string type_descriptions; |
| 19 }; | 21 }; |
| 20 | 22 |
| 21 // This class holds references to all of the known pepper plugin modules. | 23 // This class holds references to all of the known pepper plugin modules. |
| 22 class PepperPluginRegistry { | 24 class PepperPluginRegistry { |
| 23 public: | 25 public: |
| 24 static PepperPluginRegistry* GetInstance(); | 26 static PepperPluginRegistry* GetInstance(); |
| 25 | 27 |
| 26 // Returns the list of known pepper plugins. This method is static so that | 28 // Returns the list of known pepper plugins. This method is static so that |
| 27 // it can be used by the browser process, which has no need to load the | 29 // it can be used by the browser process, which has no need to load the |
| 28 // pepper plugin modules. | 30 // pepper plugin modules. |
| (...skipping 12 matching lines...) Expand all Loading... |
| 41 static void GetInternalPluginInfo(InternalPluginInfoList* plugin_info); | 43 static void GetInternalPluginInfo(InternalPluginInfoList* plugin_info); |
| 42 | 44 |
| 43 PepperPluginRegistry(); | 45 PepperPluginRegistry(); |
| 44 | 46 |
| 45 typedef scoped_refptr<pepper::PluginModule> ModuleHandle; | 47 typedef scoped_refptr<pepper::PluginModule> ModuleHandle; |
| 46 typedef std::map<FilePath, ModuleHandle> ModuleMap; | 48 typedef std::map<FilePath, ModuleHandle> ModuleMap; |
| 47 ModuleMap modules_; | 49 ModuleMap modules_; |
| 48 }; | 50 }; |
| 49 | 51 |
| 50 #endif // CHROME_COMMON_PEPPER_PLUGIN_REGISTRY_H_ | 52 #endif // CHROME_COMMON_PEPPER_PLUGIN_REGISTRY_H_ |
| OLD | NEW |