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

Side by Side Diff: webkit/plugins/npapi/plugin_list.h

Issue 8741006: Add exports needed for glue to build as a component. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase to r112585 Created 9 years 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 | « webkit/plugins/npapi/plugin_lib.h ('k') | webkit/plugins/npapi/webplugin.h » ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_PLUGINS_NPAPI_PLUGIN_LIST_H_ 5 #ifndef WEBKIT_PLUGINS_NPAPI_PLUGIN_LIST_H_
6 #define WEBKIT_PLUGINS_NPAPI_PLUGIN_LIST_H_ 6 #define WEBKIT_PLUGINS_NPAPI_PLUGIN_LIST_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
11 #include <vector> 11 #include <vector>
12 12
13 #include "base/basictypes.h" 13 #include "base/basictypes.h"
14 #include "base/callback.h" 14 #include "base/callback.h"
15 #include "base/file_path.h" 15 #include "base/file_path.h"
16 #include "base/memory/linked_ptr.h" 16 #include "base/memory/linked_ptr.h"
17 #include "base/memory/scoped_vector.h" 17 #include "base/memory/scoped_vector.h"
18 #include "base/synchronization/lock.h" 18 #include "base/synchronization/lock.h"
19 #include "third_party/npapi/bindings/nphostapi.h" 19 #include "third_party/npapi/bindings/nphostapi.h"
20 #include "webkit/plugins/npapi/plugin_group.h" 20 #include "webkit/plugins/npapi/plugin_group.h"
21 #include "webkit/plugins/webkit_plugins_export.h"
21 #include "webkit/plugins/webplugininfo.h" 22 #include "webkit/plugins/webplugininfo.h"
22 23
23 class GURL; 24 class GURL;
24 25
25 namespace base { 26 namespace base {
26 27
27 template <typename T> 28 template <typename T>
28 struct DefaultLazyInstanceTraits; 29 struct DefaultLazyInstanceTraits;
29 30
30 } // namespace base 31 } // namespace base
31 32
32 namespace webkit { 33 namespace webkit {
33 namespace npapi { 34 namespace npapi {
34 35
35 extern FilePath::CharType kDefaultPluginLibraryName[]; 36 WEBKIT_PLUGINS_EXPORT extern FilePath::CharType kDefaultPluginLibraryName[];
36 37
37 // This struct holds entry points into a plugin. The entry points are 38 // This struct holds entry points into a plugin. The entry points are
38 // slightly different between Win/Mac and Unixes. Note that the interface for 39 // slightly different between Win/Mac and Unixes. Note that the interface for
39 // querying plugins is synchronous and it is preferable to use a higher-level 40 // querying plugins is synchronous and it is preferable to use a higher-level
40 // asynchronous information to query information. 41 // asynchronous information to query information.
41 struct PluginEntryPoints { 42 struct PluginEntryPoints {
42 #if !defined(OS_POSIX) || defined(OS_MACOSX) 43 #if !defined(OS_POSIX) || defined(OS_MACOSX)
43 NP_GetEntryPointsFunc np_getentrypoints; 44 NP_GetEntryPointsFunc np_getentrypoints;
44 #endif 45 #endif
45 NP_InitializeFunc np_initialize; 46 NP_InitializeFunc np_initialize;
46 NP_ShutdownFunc np_shutdown; 47 NP_ShutdownFunc np_shutdown;
47 }; 48 };
48 49
49 // The PluginList is responsible for loading our NPAPI based plugins. It does 50 // The PluginList is responsible for loading our NPAPI based plugins. It does
50 // so in whatever manner is appropriate for the platform. On Windows, it loads 51 // so in whatever manner is appropriate for the platform. On Windows, it loads
51 // plugins from a known directory by looking for DLLs which start with "NP", 52 // plugins from a known directory by looking for DLLs which start with "NP",
52 // and checking to see if they are valid NPAPI libraries. On the Mac, it walks 53 // and checking to see if they are valid NPAPI libraries. On the Mac, it walks
53 // the machine-wide and user plugin directories and loads anything that has 54 // the machine-wide and user plugin directories and loads anything that has
54 // the correct types. On Linux, it walks the plugin directories as well 55 // the correct types. On Linux, it walks the plugin directories as well
55 // (e.g. /usr/lib/browser-plugins/). 56 // (e.g. /usr/lib/browser-plugins/).
56 // This object is thread safe. 57 // This object is thread safe.
57 class PluginList { 58 class WEBKIT_PLUGINS_EXPORT PluginList {
58 public: 59 public:
59 // Gets the one instance of the PluginList. 60 // Gets the one instance of the PluginList.
60 static PluginList* Singleton(); 61 static PluginList* Singleton();
61 62
62 // Returns true if we're in debug-plugin-loading mode. This is controlled 63 // Returns true if we're in debug-plugin-loading mode. This is controlled
63 // by a command line switch. 64 // by a command line switch.
64 static bool DebugPluginLoading(); 65 static bool DebugPluginLoading();
65 66
66 // Cause the plugin list to refresh next time they are accessed, regardless 67 // Cause the plugin list to refresh next time they are accessed, regardless
67 // of whether they are already loaded. 68 // of whether they are already loaded.
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
296 // Set to true if the default plugin is enabled. 297 // Set to true if the default plugin is enabled.
297 bool default_plugin_enabled_; 298 bool default_plugin_enabled_;
298 299
299 DISALLOW_COPY_AND_ASSIGN(PluginList); 300 DISALLOW_COPY_AND_ASSIGN(PluginList);
300 }; 301 };
301 302
302 } // namespace npapi 303 } // namespace npapi
303 } // namespace webkit 304 } // namespace webkit
304 305
305 #endif // WEBKIT_PLUGINS_NPAPI_PLUGIN_LIST_H_ 306 #endif // WEBKIT_PLUGINS_NPAPI_PLUGIN_LIST_H_
OLDNEW
« no previous file with comments | « webkit/plugins/npapi/plugin_lib.h ('k') | webkit/plugins/npapi/webplugin.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698