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

Unified Diff: ppapi/proxy/plugin_resource_tracker.h

Issue 6905088: New thunk system for Pepper proxy and implementation (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 7 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/plugin_resource_tracker.h
===================================================================
--- ppapi/proxy/plugin_resource_tracker.h (revision 84344)
+++ ppapi/proxy/plugin_resource_tracker.h (working copy)
@@ -15,6 +15,7 @@
#include "ppapi/c/pp_resource.h"
#include "ppapi/c/pp_var.h"
#include "ppapi/proxy/host_resource.h"
+#include "ppapi/shared_impl/tracker_base.h"
template<typename T> struct DefaultSingletonTraits;
@@ -24,7 +25,7 @@
class PluginDispatcher;
class PluginResource;
-class PluginResourceTracker {
+class PluginResourceTracker : public ::ppapi::shared_impl::TrackerBase {
public:
// Called by tests that want to specify a specific ResourceTracker. This
// allows them to use a unique one each time and avoids singletons sticking
@@ -33,6 +34,7 @@
// Returns the global singleton resource tracker for the plugin.
static PluginResourceTracker* GetInstance();
+ static ::ppapi::shared_impl::TrackerBase* GetTrackerBaseInstance();
// Returns the object associated with the given resource ID, or NULL if
// there isn't one.
@@ -52,6 +54,13 @@
PP_Resource PluginResourceForHostResource(
const HostResource& resource) const;
+ // TrackerBase.
+ virtual ::ppapi::shared_impl::ResourceObjectBase* GetResourceAPI(
+ PP_Resource res);
+ virtual ::ppapi::shared_impl::FunctionGroupBase* GetFunctionAPI(
+ PP_Instance inst,
+ pp::proxy::InterfaceID id);
+
private:
friend struct DefaultSingletonTraits<PluginResourceTracker>;
friend class PluginResourceTrackerTest;

Powered by Google App Engine
This is Rietveld 408576698