| Index: ppapi/proxy/plugin_var_tracker.cc
|
| diff --git a/ppapi/proxy/plugin_var_tracker.cc b/ppapi/proxy/plugin_var_tracker.cc
|
| index a9cbd9c7a62bd2e6fdefc9b4b7f4d2c552ed8ba6..2d88f9ca779e8158876130e544fe8fb0c85a490e 100644
|
| --- a/ppapi/proxy/plugin_var_tracker.cc
|
| +++ b/ppapi/proxy/plugin_var_tracker.cc
|
| @@ -10,6 +10,7 @@
|
| #include "ppapi/c/dev/ppp_class_deprecated.h"
|
| #include "ppapi/c/ppb_var.h"
|
| #include "ppapi/proxy/file_system_resource.h"
|
| +#include "ppapi/proxy/media_stream_video_track_resource.h"
|
| #include "ppapi/proxy/plugin_array_buffer_var.h"
|
| #include "ppapi/proxy/plugin_dispatcher.h"
|
| #include "ppapi/proxy/plugin_globals.h"
|
| @@ -172,10 +173,10 @@ PP_Var PluginVarTracker::MakeResourcePPVarFromMessage(
|
| const IPC::Message& creation_message,
|
| int pending_renderer_id,
|
| int pending_browser_id) {
|
| - DCHECK(pending_renderer_id);
|
| - DCHECK(pending_browser_id);
|
| switch (creation_message.type()) {
|
| case PpapiPluginMsg_FileSystem_CreateFromPendingHost::ID: {
|
| + DCHECK(pending_renderer_id);
|
| + DCHECK(pending_browser_id);
|
| PP_FileSystemType file_system_type;
|
| if (!UnpackMessage<PpapiPluginMsg_FileSystem_CreateFromPendingHost>(
|
| creation_message, &file_system_type)) {
|
| @@ -194,6 +195,22 @@ PP_Var PluginVarTracker::MakeResourcePPVarFromMessage(
|
| file_system_type))->GetReference();
|
| return MakeResourcePPVar(pp_resource);
|
| }
|
| + case PpapiPluginMsg_MediaStreamVideoTrack_CreateFromPendingHost::ID: {
|
| + DCHECK(pending_renderer_id);
|
| + std::string id;
|
| + if (!UnpackMessage<
|
| + PpapiPluginMsg_MediaStreamVideoTrack_CreateFromPendingHost>(
|
| + creation_message, &id)) {
|
| + NOTREACHED() <<
|
| + "Invalid message of type "
|
| + "PpapiPluginMsg_MediaStreamVideoTrack_CreateFromPendingHost";
|
| + return PP_MakeNull();
|
| + }
|
| + MediaStreamVideoTrackResource *resource =
|
| + new MediaStreamVideoTrackResource(GetConnectionForInstance(instance),
|
| + instance, pending_renderer_id, id);
|
| + return MakeResourcePPVar(resource->GetReference());
|
| + }
|
| default: {
|
| NOTREACHED() << "Creation message has unexpected type "
|
| << creation_message.type();
|
|
|