Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef PPAPI_PROXY_PPB_INSTANCE_PROXY_H_ | 5 #ifndef PPAPI_PROXY_PPB_INSTANCE_PROXY_H_ |
| 6 #define PPAPI_PROXY_PPB_INSTANCE_PROXY_H_ | 6 #define PPAPI_PROXY_PPB_INSTANCE_PROXY_H_ |
| 7 | 7 |
| 8 #include "ppapi/c/pp_instance.h" | 8 #include "ppapi/c/pp_instance.h" |
| 9 #include "ppapi/c/pp_resource.h" | 9 #include "ppapi/c/pp_resource.h" |
| 10 #include "ppapi/c/pp_time.h" | 10 #include "ppapi/c/pp_time.h" |
| 11 #include "ppapi/c/pp_var.h" | 11 #include "ppapi/c/pp_var.h" |
| 12 #include "ppapi/proxy/interface_proxy.h" | 12 #include "ppapi/proxy/interface_proxy.h" |
| 13 #include "ppapi/proxy/proxy_completion_callback_factory.h" | 13 #include "ppapi/proxy/proxy_completion_callback_factory.h" |
| 14 #include "ppapi/shared_impl/host_resource.h" | 14 #include "ppapi/shared_impl/host_resource.h" |
| 15 #include "ppapi/shared_impl/ppb_instance_shared.h" | 15 #include "ppapi/shared_impl/ppb_instance_shared.h" |
| 16 #include "ppapi/thunk/ppb_instance_api.h" | 16 #include "ppapi/thunk/ppb_instance_api.h" |
| 17 #include "ppapi/utility/completion_callback_factory.h" | 17 #include "ppapi/utility/completion_callback_factory.h" |
| 18 | 18 |
| 19 // Windows headers interfere with this file. | 19 // Windows headers interfere with this file. |
| 20 #ifdef PostMessage | 20 #ifdef PostMessage |
| 21 #undef PostMessage | 21 #undef PostMessage |
| 22 #endif | 22 #endif |
| 23 | 23 |
| 24 struct PP_DecryptedBlockInfo; | |
|
Tom Finegan
2012/08/20 21:31:45
Should I include pp_content_decryptor.h up above i
xhwang
2012/08/20 22:19:31
The rule is always forward declare if you can. So
| |
| 25 | |
| 24 namespace ppapi { | 26 namespace ppapi { |
| 25 namespace proxy { | 27 namespace proxy { |
| 26 | 28 |
| 27 class SerializedVarReceiveInput; | 29 class SerializedVarReceiveInput; |
| 28 class SerializedVarOutParam; | 30 class SerializedVarOutParam; |
| 29 class SerializedVarReturnValue; | 31 class SerializedVarReturnValue; |
| 30 | 32 |
| 31 class PPB_Instance_Proxy : public InterfaceProxy, | 33 class PPB_Instance_Proxy : public InterfaceProxy, |
| 32 public PPB_Instance_Shared { | 34 public PPB_Instance_Shared { |
| 33 public: | 35 public: |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 127 PP_Var session_id, | 129 PP_Var session_id, |
| 128 PP_Resource message, | 130 PP_Resource message, |
| 129 PP_Var default_url) OVERRIDE; | 131 PP_Var default_url) OVERRIDE; |
| 130 virtual void KeyError(PP_Instance instance, | 132 virtual void KeyError(PP_Instance instance, |
| 131 PP_Var key_system, | 133 PP_Var key_system, |
| 132 PP_Var session_id, | 134 PP_Var session_id, |
| 133 int32_t media_error, | 135 int32_t media_error, |
| 134 int32_t system_code) OVERRIDE; | 136 int32_t system_code) OVERRIDE; |
| 135 virtual void DeliverBlock(PP_Instance instance, | 137 virtual void DeliverBlock(PP_Instance instance, |
| 136 PP_Resource decrypted_block, | 138 PP_Resource decrypted_block, |
| 137 int32_t request_id) OVERRIDE; | 139 const PP_DecryptedBlockInfo* block_info) OVERRIDE; |
| 138 virtual void DeliverFrame(PP_Instance instance, | 140 virtual void DeliverFrame(PP_Instance instance, |
| 139 PP_Resource decrypted_frame, | 141 PP_Resource decrypted_frame, |
| 140 int32_t request_id) OVERRIDE; | 142 const PP_DecryptedBlockInfo* block_info) OVERRIDE; |
| 141 virtual void DeliverSamples(PP_Instance instance, | 143 virtual void DeliverSamples(PP_Instance instance, |
| 142 PP_Resource decrypted_samples, | 144 PP_Resource decrypted_samples, |
| 143 int32_t request_id) OVERRIDE; | 145 const PP_DecryptedBlockInfo* block_info) OVERRIDE; |
| 144 #endif // !defined(OS_NACL) | 146 #endif // !defined(OS_NACL) |
| 145 | 147 |
| 146 static const ApiID kApiID = API_ID_PPB_INSTANCE; | 148 static const ApiID kApiID = API_ID_PPB_INSTANCE; |
| 147 | 149 |
| 148 private: | 150 private: |
| 149 // Plugin -> Host message handlers. | 151 // Plugin -> Host message handlers. |
| 150 void OnHostMsgGetWindowObject(PP_Instance instance, | 152 void OnHostMsgGetWindowObject(PP_Instance instance, |
| 151 SerializedVarReturnValue result); | 153 SerializedVarReturnValue result); |
| 152 void OnHostMsgGetOwnerElementObject(PP_Instance instance, | 154 void OnHostMsgGetOwnerElementObject(PP_Instance instance, |
| 153 SerializedVarReturnValue result); | 155 SerializedVarReturnValue result); |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 226 SerializedVarReceiveInput session_id, | 228 SerializedVarReceiveInput session_id, |
| 227 PP_Resource message, | 229 PP_Resource message, |
| 228 SerializedVarReceiveInput default_url); | 230 SerializedVarReceiveInput default_url); |
| 229 virtual void OnHostMsgKeyError(PP_Instance instance, | 231 virtual void OnHostMsgKeyError(PP_Instance instance, |
| 230 SerializedVarReceiveInput key_system, | 232 SerializedVarReceiveInput key_system, |
| 231 SerializedVarReceiveInput session_id, | 233 SerializedVarReceiveInput session_id, |
| 232 int32_t media_error, | 234 int32_t media_error, |
| 233 int32_t system_code); | 235 int32_t system_code); |
| 234 virtual void OnHostMsgDeliverBlock(PP_Instance instance, | 236 virtual void OnHostMsgDeliverBlock(PP_Instance instance, |
| 235 PP_Resource decrypted_block, | 237 PP_Resource decrypted_block, |
| 236 int32_t request_id); | 238 const std::string& serialized_block_info); |
| 237 virtual void OnHostMsgDeliverFrame(PP_Instance instance, | 239 virtual void OnHostMsgDeliverFrame(PP_Instance instance, |
| 238 PP_Resource decrypted_frame, | 240 PP_Resource decrypted_frame, |
| 239 int32_t request_id); | 241 const std::string& serialized_block_info); |
| 240 virtual void OnHostMsgDeliverSamples(PP_Instance instance, | 242 virtual void OnHostMsgDeliverSamples( |
| 241 PP_Resource decrypted_samples, | 243 PP_Instance instance, |
| 242 int32_t request_id); | 244 PP_Resource decrypted_samples, |
| 245 const std::string& serialized_block_info); | |
| 243 #endif // !defined(OS_NACL) | 246 #endif // !defined(OS_NACL) |
| 244 | 247 |
| 245 // Host -> Plugin message handlers. | 248 // Host -> Plugin message handlers. |
| 246 void OnPluginMsgMouseLockComplete(PP_Instance instance, int32_t result); | 249 void OnPluginMsgMouseLockComplete(PP_Instance instance, int32_t result); |
| 247 | 250 |
| 248 void MouseLockCompleteInHost(int32_t result, PP_Instance instance); | 251 void MouseLockCompleteInHost(int32_t result, PP_Instance instance); |
| 249 | 252 |
| 250 ProxyCompletionCallbackFactory<PPB_Instance_Proxy> callback_factory_; | 253 ProxyCompletionCallbackFactory<PPB_Instance_Proxy> callback_factory_; |
| 251 }; | 254 }; |
| 252 | 255 |
| 253 } // namespace proxy | 256 } // namespace proxy |
| 254 } // namespace ppapi | 257 } // namespace ppapi |
| 255 | 258 |
| 256 #endif // PPAPI_PROXY_PPB_INSTANCE_PROXY_H_ | 259 #endif // PPAPI_PROXY_PPB_INSTANCE_PROXY_H_ |
| OLD | NEW |