Whitelist window states to persist on ASH app windows.
[chromium-blink-merge.git] / ppapi / proxy / ppp_content_decryptor_private_proxy.h
blob5e7ecc85dbadd6dc09d6f795e7c4f2db9ad44412
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef PPAPI_PROXY_PPP_CONTENT_DECRYPTOR_PRIVATE_PROXY_H_
6 #define PPAPI_PROXY_PPP_CONTENT_DECRYPTOR_PRIVATE_PROXY_H_
8 #include <string>
10 #include "ppapi/c/pp_instance.h"
11 #include "ppapi/c/private/ppp_content_decryptor_private.h"
12 #include "ppapi/proxy/interface_proxy.h"
13 #include "ppapi/proxy/serialized_structs.h"
14 #include "ppapi/shared_impl/host_resource.h"
16 namespace ppapi {
17 namespace proxy {
19 class SerializedVarReceiveInput;
21 class PPP_ContentDecryptor_Private_Proxy : public InterfaceProxy {
22 public:
23 explicit PPP_ContentDecryptor_Private_Proxy(Dispatcher* dispatcher);
24 virtual ~PPP_ContentDecryptor_Private_Proxy();
26 static const PPP_ContentDecryptor_Private* GetProxyInterface();
28 private:
29 // InterfaceProxy implementation.
30 virtual bool OnMessageReceived(const IPC::Message& msg);
32 // Message handlers.
33 void OnMsgGenerateKeyRequest(PP_Instance instance,
34 SerializedVarReceiveInput key_system,
35 SerializedVarReceiveInput type,
36 SerializedVarReceiveInput init_data);
37 void OnMsgAddKey(PP_Instance instance,
38 SerializedVarReceiveInput session_id,
39 SerializedVarReceiveInput key,
40 SerializedVarReceiveInput init_data);
41 void OnMsgCancelKeyRequest(PP_Instance instance,
42 SerializedVarReceiveInput session_id);
43 void OnMsgDecrypt(PP_Instance instance,
44 const PPPDecryptor_Buffer& encrypted_buffer,
45 const std::string& serialized_encrypted_block_info);
46 void OnMsgInitializeAudioDecoder(
47 PP_Instance instance,
48 const std::string& decoder_config,
49 const PPPDecryptor_Buffer& extra_data_buffer);
50 void OnMsgInitializeVideoDecoder(
51 PP_Instance instance,
52 const std::string& decoder_config,
53 const PPPDecryptor_Buffer& extra_data_buffer);
54 void OnMsgDeinitializeDecoder(PP_Instance instance,
55 PP_DecryptorStreamType decoder_type,
56 uint32_t request_id);
57 void OnMsgResetDecoder(PP_Instance instance,
58 PP_DecryptorStreamType decoder_type,
59 uint32_t request_id);
60 void OnMsgDecryptAndDecode(
61 PP_Instance instance,
62 PP_DecryptorStreamType decoder_type,
63 const PPPDecryptor_Buffer& encrypted_buffer,
64 const std::string& serialized_encrypted_block_info);
66 const PPP_ContentDecryptor_Private* ppp_decryptor_impl_;
68 DISALLOW_COPY_AND_ASSIGN(PPP_ContentDecryptor_Private_Proxy);
71 } // namespace proxy
72 } // namespace ppapi
74 #endif // PPAPI_PROXY_PPP_CONTENT_DECRYPTOR_PRIVATE_PROXY_H_