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

Unified Diff: ppapi/shared_impl/var_tracker.h

Issue 26564009: [PPAPI] It is now possible to pass filesystems from JavaScript to NaCl modules. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Use a vector instead of variable-length array. (Fix Windows compile). Created 7 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 side-by-side diff with in-line comments
Download patch
Index: ppapi/shared_impl/var_tracker.h
diff --git a/ppapi/shared_impl/var_tracker.h b/ppapi/shared_impl/var_tracker.h
index 168fcb9933335d9be36a69ddc4a83a591bdd73e8..54d1bbd06ac175cd282550c928045331392a8bc2 100644
--- a/ppapi/shared_impl/var_tracker.h
+++ b/ppapi/shared_impl/var_tracker.h
@@ -21,6 +21,10 @@
#include "ppapi/shared_impl/ppapi_shared_export.h"
#include "ppapi/shared_impl/var.h"
+namespace IPC {
+class Message;
+} // namespace IPC
+
namespace ppapi {
class ArrayBufferVar;
@@ -85,6 +89,16 @@ class PPAPI_SHARED_EXPORT VarTracker {
// usually immediately put this in a scoped_refptr).
ArrayBufferVar* MakeArrayBufferVar(uint32 size_in_bytes, const void* data);
+ // Creates a new resource var from a resource creation message. Returns a
+ // PP_Var that references a new PP_Resource, both with an initial reference
+ // count of 1. If |creation_message| is empty, returns a valid, empty resource
+ // var. On the host side, |creation_message| is ignored, and an empty resource
+ // var is always returned.
+ virtual PP_Var MakeResourcePPVar(const IPC::Message& creation_message,
+ int pending_renderer_id,
+ int pending_browser_id,
+ PP_Instance instance) = 0;
+
// Creates a new resource var that points to a given resource ID. Returns a
// PP_Var that references it and has an initial reference count of 1.
// If |pp_resource| is 0, returns a valid, empty resource var. On the plugin

Powered by Google App Engine
This is Rietveld 408576698