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

Unified Diff: ppapi/proxy/ppb_core_proxy.cc

Issue 7349016: Added versioning for PPB_Core::MemAlloc and MemFree (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Minor cleanup Created 9 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: ppapi/proxy/ppb_core_proxy.cc
diff --git a/ppapi/proxy/ppb_core_proxy.cc b/ppapi/proxy/ppb_core_proxy.cc
index e3b8ab6d3e7e12b88fd527f5bd2415df20ce44b0..7773b43a6210971a1274269b652ddc458268b8dd 100644
--- a/ppapi/proxy/ppb_core_proxy.cc
+++ b/ppapi/proxy/ppb_core_proxy.cc
@@ -69,17 +69,6 @@ PP_Bool IsMainThread() {
return PP_FromBool(GetMainThreadMessageLoop()->BelongsToCurrentThread());
}
-const PPB_Core core_interface = {
- &AddRefResource,
- &ReleaseResource,
- &MemAlloc,
- &MemFree,
- &GetTime,
- &GetTimeTicks,
- &CallOnMainThread,
- &IsMainThread
-};
-
InterfaceProxy* CreateCoreProxy(Dispatcher* dispatcher,
const void* target_interface) {
return new PPB_Core_Proxy(dispatcher, target_interface);
@@ -97,6 +86,15 @@ PPB_Core_Proxy::~PPB_Core_Proxy() {
// static
const InterfaceProxy::Info* PPB_Core_Proxy::GetInfo() {
+ static const PPB_Core core_interface = {
+ &AddRefResource,
+ &ReleaseResource,
+ &GetTime,
+ &GetTimeTicks,
+ &CallOnMainThread,
+ &IsMainThread
+ };
dmichael (off chromium) 2011/07/14 05:28:21 I'm not sure moving it here buys you much. I guess
Matt Ball 2011/07/14 15:49:20 Done.
+
static const Info info = {
&core_interface,
PPB_CORE_INTERFACE,

Powered by Google App Engine
This is Rietveld 408576698