Index: ppapi/proxy/resource_creation_proxy.cc |
=================================================================== |
--- ppapi/proxy/resource_creation_proxy.cc (revision 100758) |
+++ ppapi/proxy/resource_creation_proxy.cc (working copy) |
@@ -45,12 +45,17 @@ |
namespace proxy { |
ResourceCreationProxy::ResourceCreationProxy(Dispatcher* dispatcher) |
- : dispatcher_(dispatcher) { |
+ : InterfaceProxy(dispatcher) { |
} |
ResourceCreationProxy::~ResourceCreationProxy() { |
} |
+// static |
+InterfaceProxy* ResourceCreationProxy::Create(Dispatcher* dispatcher) { |
+ return new ResourceCreationProxy(dispatcher); |
+} |
+ |
ResourceCreationAPI* ResourceCreationProxy::AsResourceCreationAPI() { |
return this; |
} |
@@ -337,7 +342,7 @@ |
} |
bool ResourceCreationProxy::Send(IPC::Message* msg) { |
- return dispatcher_->Send(msg); |
+ return dispatcher()->Send(msg); |
} |
bool ResourceCreationProxy::OnMessageReceived(const IPC::Message& msg) { |
@@ -395,14 +400,14 @@ |
// Get the shared memory handle. |
const PPB_ImageDataTrusted* trusted = |
reinterpret_cast<const PPB_ImageDataTrusted*>( |
- dispatcher_->GetLocalInterface(PPB_IMAGEDATA_TRUSTED_INTERFACE)); |
+ dispatcher()->local_get_interface()(PPB_IMAGEDATA_TRUSTED_INTERFACE)); |
uint32_t byte_count = 0; |
if (trusted) { |
int32_t handle; |
if (trusted->GetSharedMemory(resource, &handle, &byte_count) == PP_OK) { |
#if defined(OS_WIN) |
ImageHandle ih = ImageData::HandleFromInt(handle); |
- *result_image_handle = dispatcher_->ShareHandleWithRemote(ih, false); |
+ *result_image_handle = dispatcher()->ShareHandleWithRemote(ih, false); |
#else |
*result_image_handle = ImageData::HandleFromInt(handle); |
#endif |