OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_PPP_INSTANCE_PRIVATE_PROXY_H_ | 5 #ifndef PPAPI_PROXY_PPP_INSTANCE_PRIVATE_PROXY_H_ |
6 #define PPAPI_PROXY_PPP_INSTANCE_PRIVATE_PROXY_H_ | 6 #define PPAPI_PROXY_PPP_INSTANCE_PRIVATE_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_var.h" | 10 #include "ppapi/c/pp_var.h" |
11 #include "ppapi/proxy/interface_proxy.h" | 11 #include "ppapi/proxy/interface_proxy.h" |
12 #include "ppapi/shared_impl/host_resource.h" | 12 #include "ppapi/shared_impl/host_resource.h" |
13 | 13 |
14 struct PPP_Instance_Private; | 14 struct PPP_Instance_Private; |
15 | 15 |
16 namespace pp { | 16 namespace ppapi { |
17 namespace proxy { | 17 namespace proxy { |
18 | 18 |
19 class SerializedVarReturnValue; | 19 class SerializedVarReturnValue; |
20 | 20 |
21 class PPP_Instance_Private_Proxy : public InterfaceProxy { | 21 class PPP_Instance_Private_Proxy : public InterfaceProxy { |
22 public: | 22 public: |
23 PPP_Instance_Private_Proxy(Dispatcher* dispatcher, | 23 PPP_Instance_Private_Proxy(Dispatcher* dispatcher, |
24 const void* target_interface); | 24 const void* target_interface); |
25 virtual ~PPP_Instance_Private_Proxy(); | 25 virtual ~PPP_Instance_Private_Proxy(); |
26 | 26 |
27 static const Info* GetInfo(); | 27 static const Info* GetInfo(); |
28 | 28 |
29 const PPP_Instance_Private* ppp_instance_private_target() const { | 29 const PPP_Instance_Private* ppp_instance_private_target() const { |
30 return reinterpret_cast<const PPP_Instance_Private*>(target_interface()); | 30 return reinterpret_cast<const PPP_Instance_Private*>(target_interface()); |
31 } | 31 } |
32 | 32 |
33 private: | 33 private: |
34 // InterfaceProxy implementation. | 34 // InterfaceProxy implementation. |
35 virtual bool OnMessageReceived(const IPC::Message& msg); | 35 virtual bool OnMessageReceived(const IPC::Message& msg); |
36 | 36 |
37 // Message handlers. | 37 // Message handlers. |
38 void OnMsgGetInstanceObject(PP_Instance instance, | 38 void OnMsgGetInstanceObject(PP_Instance instance, |
39 SerializedVarReturnValue result); | 39 SerializedVarReturnValue result); |
40 }; | 40 }; |
41 | 41 |
42 } // namespace proxy | 42 } // namespace proxy |
43 } // namespace pp | 43 } // namespace ppapi |
44 | 44 |
45 #endif // PPAPI_PROXY_PPP_INSTANCE_PRIVATE_PROXY_H_ | 45 #endif // PPAPI_PROXY_PPP_INSTANCE_PRIVATE_PROXY_H_ |
OLD | NEW |