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

Side by Side Diff: ppapi/shared_impl/ppapi_globals.h

Issue 10091003: Convert flash to thunk (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 8 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 | « ppapi/proxy/ppb_instance_proxy.cc ('k') | ppapi/shared_impl/test_globals.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 PPAPI_SHARED_IMPL_PPAPI_GLOBALS_H_ 5 #ifndef PPAPI_SHARED_IMPL_PPAPI_GLOBALS_H_
6 #define PPAPI_SHARED_IMPL_PPAPI_GLOBALS_H_ 6 #define PPAPI_SHARED_IMPL_PPAPI_GLOBALS_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 const std::string& value) = 0; 88 const std::string& value) = 0;
89 89
90 // Returns the function object corresponding to the given ID, or NULL if 90 // Returns the function object corresponding to the given ID, or NULL if
91 // there isn't one. 91 // there isn't one.
92 virtual FunctionGroupBase* GetFunctionAPI(PP_Instance inst, ApiID id) = 0; 92 virtual FunctionGroupBase* GetFunctionAPI(PP_Instance inst, ApiID id) = 0;
93 93
94 // Returns the PP_Module associated with the given PP_Instance, or 0 on 94 // Returns the PP_Module associated with the given PP_Instance, or 0 on
95 // failure. 95 // failure.
96 virtual PP_Module GetModuleForInstance(PP_Instance instance) = 0; 96 virtual PP_Module GetModuleForInstance(PP_Instance instance) = 0;
97 97
98 // Returns the command line for the process.
99 virtual std::string GetCmdLine() = 0;
100
101 // Preloads the font on Windows, does nothing on other platforms.
102 // TODO(brettw) remove this by passing the instance into the API so we don't
103 // have to have it on the globals.
104 virtual void PreCacheFontForFlash(const void* logfontw) = 0;
105
98 virtual bool IsHostGlobals() const; 106 virtual bool IsHostGlobals() const;
99 virtual bool IsPluginGlobals() const; 107 virtual bool IsPluginGlobals() const;
100 108
101 private: 109 private:
102 // Return the thread-local pointer which is used only for unit testing. It 110 // Return the thread-local pointer which is used only for unit testing. It
103 // should always be NULL when running in production. It allows separate 111 // should always be NULL when running in production. It allows separate
104 // threads to have distinct "globals". 112 // threads to have distinct "globals".
105 static PpapiGlobals* GetThreadLocalPointer(); 113 static PpapiGlobals* GetThreadLocalPointer();
106 114
107 static PpapiGlobals* ppapi_globals_; 115 static PpapiGlobals* ppapi_globals_;
108 116
109 DISALLOW_COPY_AND_ASSIGN(PpapiGlobals); 117 DISALLOW_COPY_AND_ASSIGN(PpapiGlobals);
110 }; 118 };
111 119
112 } // namespace ppapi 120 } // namespace ppapi
113 121
114 #endif // PPAPI_SHARED_IMPL_PPAPI_GLOBALS_H_ 122 #endif // PPAPI_SHARED_IMPL_PPAPI_GLOBALS_H_
OLDNEW
« no previous file with comments | « ppapi/proxy/ppb_instance_proxy.cc ('k') | ppapi/shared_impl/test_globals.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698