Index: ppapi/proxy/ppp_content_decryptor_proxy.h |
diff --git a/ppapi/proxy/ppp_content_decryptor_proxy.h b/ppapi/proxy/ppp_content_decryptor_proxy.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..45bdacf2459efceb24c2cba087f6eca92a18079b |
--- /dev/null |
+++ b/ppapi/proxy/ppp_content_decryptor_proxy.h |
@@ -0,0 +1,54 @@ |
+// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef PPAPI_PROXY_PPP_CONTENT_DECRYPTOR_PROXY_H_ |
+#define PPAPI_PROXY_PPP_CONTENT_DECRYPTOR_PROXY_H_ |
+ |
+#include "ppapi/c/dev/ppp_content_decryptor_dev.h" |
+#include "ppapi/c/pp_instance.h" |
+#include "ppapi/proxy/interface_proxy.h" |
+#include "ppapi/shared_impl/host_resource.h" |
+ |
+namespace ppapi { |
+namespace proxy { |
+ |
+class SerializedVarReceiveInput; |
+ |
+class PPP_ContentDecryptor_Proxy : public InterfaceProxy { |
+ public: |
+ PPP_ContentDecryptor_Proxy(Dispatcher* dispatcher); |
+ virtual ~PPP_ContentDecryptor_Proxy(); |
+ |
+ static const Info* GetInfo(); |
+ |
+ // InterfaceProxy implementation. |
+ virtual bool OnMessageReceived(const IPC::Message& msg); |
+ |
+ private: |
+ // Message handlers. |
+ // TODO(tomfinegan): Not sure if I want to use OnPluginMsg or OnMsg. |
+ void OnPluginMsgGenerateKeyRequest(PP_Instance instance, |
+ SerializedVarReceiveInput key_system, |
+ SerializedVarReceiveInput init_data); |
+ void OnPluginMsgAddKey(PP_Instance instance, |
+ SerializedVarReceiveInput session_id, |
+ SerializedVarReceiveInput key); |
+ void OnPluginMsgCancelKeyRequest(PP_Instance instance, |
+ SerializedVarReceiveInput session_id); |
+ void OnPluginMsgDecrypt(PP_Instance instance, |
+ PP_Resource encrypted_block, |
+ uint64_t request_id); |
+ void OnPluginMsgDecryptAndDecode(PP_Instance instance, |
+ PP_Resource encrypted_block, |
+ uint64_t request_id); |
+ |
+ const PPP_ContentDecryptor_Dev* ppp_decryptor_impl_; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(PPP_ContentDecryptor_Proxy); |
+}; |
+ |
+} // namespace proxy |
+} // namespace ppapi |
+ |
+#endif // PPAPI_PROXY_PPP_CONTENT_DECRYPTOR_PROXY_H_ |