| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_BROWSER_EXTENSIONS_PLUGIN_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_PLUGIN_MANAGER_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_PLUGIN_MANAGER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_PLUGIN_MANAGER_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 | 37 |
| 38 // We implement some Pepper plug-ins using NaCl to take advantage of NaCl's | 38 // We implement some Pepper plug-ins using NaCl to take advantage of NaCl's |
| 39 // strong sandbox. Typically, these NaCl modules are stored in extensions | 39 // strong sandbox. Typically, these NaCl modules are stored in extensions |
| 40 // and registered here. Not all NaCl modules need to register for a MIME | 40 // and registered here. Not all NaCl modules need to register for a MIME |
| 41 // type, just the ones that are responsible for rendering a particular MIME | 41 // type, just the ones that are responsible for rendering a particular MIME |
| 42 // type, like application/pdf. Note: We only register NaCl modules in the | 42 // type, like application/pdf. Note: We only register NaCl modules in the |
| 43 // browser process. | 43 // browser process. |
| 44 void RegisterNaClModule(const NaClModuleInfo& info); | 44 void RegisterNaClModule(const NaClModuleInfo& info); |
| 45 void UnregisterNaClModule(const NaClModuleInfo& info); | 45 void UnregisterNaClModule(const NaClModuleInfo& info); |
| 46 | 46 |
| 47 void RegisterMimeTypeHandler(const std::string& extension_id); | |
| 48 void UnregisterMimeTypeHandler(const std::string& extension_id); | |
| 49 | |
| 50 // Call UpdatePluginListWithNaClModules() after registering or unregistering | 47 // Call UpdatePluginListWithNaClModules() after registering or unregistering |
| 51 // a NaCl module to see those changes reflected in the PluginList. | 48 // a NaCl module to see those changes reflected in the PluginList. |
| 52 void UpdatePluginListWithNaClModules(); | 49 void UpdatePluginListWithNaClModules(); |
| 53 | 50 |
| 54 extensions::NaClModuleInfo::List::iterator FindNaClModule(const GURL& url); | 51 extensions::NaClModuleInfo::List::iterator FindNaClModule(const GURL& url); |
| 55 | 52 |
| 56 // ExtensionRegistryObserver implementation. | 53 // ExtensionRegistryObserver implementation. |
| 57 virtual void OnExtensionLoaded(content::BrowserContext* browser_context, | 54 virtual void OnExtensionLoaded(content::BrowserContext* browser_context, |
| 58 const Extension* extension) OVERRIDE; | 55 const Extension* extension) OVERRIDE; |
| 59 virtual void OnExtensionUnloaded( | 56 virtual void OnExtensionUnloaded( |
| (...skipping 14 matching lines...) Expand all Loading... |
| 74 Profile* profile_; | 71 Profile* profile_; |
| 75 | 72 |
| 76 // Listen to extension load, unloaded notifications. | 73 // Listen to extension load, unloaded notifications. |
| 77 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> | 74 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> |
| 78 extension_registry_observer_; | 75 extension_registry_observer_; |
| 79 }; | 76 }; |
| 80 | 77 |
| 81 } // namespace extensions | 78 } // namespace extensions |
| 82 | 79 |
| 83 #endif // CHROME_BROWSER_EXTENSIONS_PLUGIN_MANAGER_H_ | 80 #endif // CHROME_BROWSER_EXTENSIONS_PLUGIN_MANAGER_H_ |
| OLD | NEW |