Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(257)

Side by Side Diff: webkit/glue/plugins/plugin_lib.h

Issue 153002: NaCl-Chrome integration - step 1 (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 11 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ipc/ipc_message_utils.h ('k') | webkit/glue/plugins/webplugin_delegate_impl_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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_PLUGIN_PLUGIN_LIB_H__ 5 #ifndef WEBKIT_GLUE_PLUGIN_PLUGIN_LIB_H__
6 #define WEBKIT_GLUE_PLUGIN_PLUGIN_LIB_H__ 6 #define WEBKIT_GLUE_PLUGIN_PLUGIN_LIB_H__
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 // Creates a new instance of this plugin. 54 // Creates a new instance of this plugin.
55 PluginInstance* CreateInstance(const std::string& mime_type); 55 PluginInstance* CreateInstance(const std::string& mime_type);
56 56
57 // Called by the instance when the instance is tearing down. 57 // Called by the instance when the instance is tearing down.
58 void CloseInstance(); 58 void CloseInstance();
59 59
60 // Gets information about this plugin and the mime types that it 60 // Gets information about this plugin and the mime types that it
61 // supports. 61 // supports.
62 const WebPluginInfo& plugin_info() { return web_plugin_info_; } 62 const WebPluginInfo& plugin_info() { return web_plugin_info_; }
63 63
64 bool internal() { return internal_; }
65
64 // 66 //
65 // NPAPI functions 67 // NPAPI functions
66 // 68 //
67 69
68 // NPAPI method to initialize a Plugin. 70 // NPAPI method to initialize a Plugin.
69 // Initialize can be safely called multiple times 71 // Initialize can be safely called multiple times
70 NPError NP_Initialize(); 72 NPError NP_Initialize();
71 73
72 // NPAPI method to shutdown a Plugin. 74 // NPAPI method to shutdown a Plugin.
73 void NP_Shutdown(void); 75 void NP_Shutdown(void);
(...skipping 10 matching lines...) Expand all
84 // Returns true if it is a legitimate plugin, false otherwise 86 // Returns true if it is a legitimate plugin, false otherwise
85 bool Load(); 87 bool Load();
86 88
87 // Unloads the plugin library. 89 // Unloads the plugin library.
88 void Unload(); 90 void Unload();
89 91
90 // Shutdown the plugin library. 92 // Shutdown the plugin library.
91 void Shutdown(); 93 void Shutdown();
92 94
93 private: 95 private:
94 bool internal_; // Whether this an internal plugin. 96 bool internal_; // True for plugins that are built-in into chrome binaries.
95 WebPluginInfo web_plugin_info_; // supported mime types, description 97 WebPluginInfo web_plugin_info_; // supported mime types, description
96 base::NativeLibrary library_; // the opened library reference 98 base::NativeLibrary library_; // the opened library reference
97 NPPluginFuncs plugin_funcs_; // the struct of plugin side functions 99 NPPluginFuncs plugin_funcs_; // the struct of plugin side functions
98 bool initialized_; // is the plugin initialized 100 bool initialized_; // is the plugin initialized
99 NPSavedData *saved_data_; // persisted plugin info for NPAPI 101 NPSavedData *saved_data_; // persisted plugin info for NPAPI
100 int instance_count_; // count of plugins in use 102 int instance_count_; // count of plugins in use
101 103
102 // Function pointers to entry points into the plugin. 104 // Function pointers to entry points into the plugin.
103 PluginEntryPoints entry_points_; 105 PluginEntryPoints entry_points_;
104 106
105 DISALLOW_EVIL_CONSTRUCTORS(PluginLib); 107 DISALLOW_EVIL_CONSTRUCTORS(PluginLib);
106 }; 108 };
107 109
108 } // namespace NPAPI 110 } // namespace NPAPI
109 111
110 #endif // WEBKIT_GLUE_PLUGIN_PLUGIN_LIB_H__ 112 #endif // WEBKIT_GLUE_PLUGIN_PLUGIN_LIB_H__
OLDNEW
« no previous file with comments | « ipc/ipc_message_utils.h ('k') | webkit/glue/plugins/webplugin_delegate_impl_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698