| Index: ppapi/proxy/ppp_content_decryptor_private_proxy.cc
|
| diff --git a/ppapi/proxy/ppp_content_decryptor_private_proxy.cc b/ppapi/proxy/ppp_content_decryptor_private_proxy.cc
|
| index 167e4764d38149ae59d5d455a5a802c9ce21a152..da0209764baedbafb28057375f0fdee29b0da0e1 100644
|
| --- a/ppapi/proxy/ppp_content_decryptor_private_proxy.cc
|
| +++ b/ppapi/proxy/ppp_content_decryptor_private_proxy.cc
|
| @@ -142,6 +142,22 @@ void CreateSession(PP_Instance instance,
|
| SerializedVarSendInput(dispatcher, init_data)));
|
| }
|
|
|
| +void LoadSession(PP_Instance instance,
|
| + uint32_t session_id,
|
| + PP_Var web_session_id) {
|
| + HostDispatcher* dispatcher = HostDispatcher::GetForInstance(instance);
|
| + if (!dispatcher) {
|
| + NOTREACHED();
|
| + return;
|
| + }
|
| +
|
| + dispatcher->Send(new PpapiMsg_PPPContentDecryptor_LoadSession(
|
| + API_ID_PPP_CONTENT_DECRYPTOR_PRIVATE,
|
| + instance,
|
| + session_id,
|
| + SerializedVarSendInput(dispatcher, web_session_id)));
|
| +}
|
| +
|
| void UpdateSession(PP_Instance instance, uint32_t session_id, PP_Var response) {
|
| HostDispatcher* dispatcher = HostDispatcher::GetForInstance(instance);
|
| if (!dispatcher) {
|
| @@ -357,6 +373,7 @@ void DecryptAndDecode(PP_Instance instance,
|
| static const PPP_ContentDecryptor_Private content_decryptor_interface = {
|
| &Initialize,
|
| &CreateSession,
|
| + &LoadSession,
|
| &UpdateSession,
|
| &ReleaseSession,
|
| &Decrypt,
|
| @@ -401,6 +418,8 @@ bool PPP_ContentDecryptor_Private_Proxy::OnMessageReceived(
|
| OnMsgInitialize)
|
| IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_CreateSession,
|
| OnMsgCreateSession)
|
| + IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_LoadSession,
|
| + OnMsgLoadSession)
|
| IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_UpdateSession,
|
| OnMsgUpdateSession)
|
| IPC_MESSAGE_HANDLER(PpapiMsg_PPPContentDecryptor_ReleaseSession,
|
| @@ -448,6 +467,19 @@ void PPP_ContentDecryptor_Private_Proxy::OnMsgCreateSession(
|
| }
|
| }
|
|
|
| +void PPP_ContentDecryptor_Private_Proxy::OnMsgLoadSession(
|
| + PP_Instance instance,
|
| + uint32_t session_id,
|
| + SerializedVarReceiveInput web_session_id) {
|
| + if (ppp_decryptor_impl_) {
|
| + CallWhileUnlocked(
|
| + ppp_decryptor_impl_->LoadSession,
|
| + instance,
|
| + session_id,
|
| + ExtractReceivedVarAndAddRef(dispatcher(), &web_session_id));
|
| + }
|
| +}
|
| +
|
| void PPP_ContentDecryptor_Private_Proxy::OnMsgUpdateSession(
|
| PP_Instance instance,
|
| uint32_t session_id,
|
|
|