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 WEBKIT_GLUE_PLUGINS_PLUGIN_LIB_H_ | 5 #ifndef WEBKIT_PLUGINS_NPAPI_PLUGIN_LIB_H_ |
6 #define WEBKIT_GLUE_PLUGINS_PLUGIN_LIB_H_ | 6 #define WEBKIT_PLUGINS_NPAPI_PLUGIN_LIB_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
12 #include "base/native_library.h" | 12 #include "base/native_library.h" |
13 #include "base/ref_counted.h" | 13 #include "base/ref_counted.h" |
14 #include "build/build_config.h" | 14 #include "build/build_config.h" |
15 #include "webkit/glue/plugins/plugin_list.h" | 15 #include "webkit/plugins/npapi/plugin_list.h" |
16 #include "webkit/glue/plugins/webplugin.h" | 16 #include "webkit/plugins/npapi/webplugin.h" |
17 | 17 |
18 class FilePath; | 18 class FilePath; |
19 struct WebPluginInfo; | 19 struct WebPluginInfo; |
20 | 20 |
21 namespace NPAPI { | 21 namespace webkit { |
| 22 namespace npapi { |
22 | 23 |
23 class PluginInstance; | 24 class PluginInstance; |
24 | 25 |
25 // A PluginLib is a single NPAPI Plugin Library, and is the lifecycle | 26 // A PluginLib is a single NPAPI Plugin Library, and is the lifecycle |
26 // manager for new PluginInstances. | 27 // manager for new PluginInstances. |
27 class PluginLib : public base::RefCounted<PluginLib> { | 28 class PluginLib : public base::RefCounted<PluginLib> { |
28 public: | 29 public: |
29 static PluginLib* CreatePluginLib(const FilePath& filename); | 30 static PluginLib* CreatePluginLib(const FilePath& filename); |
30 | 31 |
31 // Creates a WebPluginInfo structure given a plugin's path. On success | 32 // Creates a WebPluginInfo structure given a plugin's path. On success |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 NPSavedData *saved_data_; // Persisted plugin info for NPAPI. | 109 NPSavedData *saved_data_; // Persisted plugin info for NPAPI. |
109 int instance_count_; // Count of plugins in use. | 110 int instance_count_; // Count of plugins in use. |
110 bool skip_unload_; // True if library_ should not be unloaded. | 111 bool skip_unload_; // True if library_ should not be unloaded. |
111 | 112 |
112 // Function pointers to entry points into the plugin. | 113 // Function pointers to entry points into the plugin. |
113 PluginEntryPoints entry_points_; | 114 PluginEntryPoints entry_points_; |
114 | 115 |
115 DISALLOW_COPY_AND_ASSIGN(PluginLib); | 116 DISALLOW_COPY_AND_ASSIGN(PluginLib); |
116 }; | 117 }; |
117 | 118 |
118 } // namespace NPAPI | 119 } // namespace npapi |
| 120 } // namespace webkit |
119 | 121 |
120 #endif // WEBKIT_GLUE_PLUGINS_PLUGIN_LIB_H_ | 122 #endif // WEBKIT_PLUGINS_NPAPI_PLUGIN_LIB_H_ |
OLD | NEW |