summaryrefslogtreecommitdiff
path: root/libs/ui/ISurfaceFlingerClient.cpp
diff options
context:
space:
mode:
author Mathias Agopian <mathias@google.com> 2009-07-06 14:52:04 -0700
committer Mathias Agopian <mathias@google.com> 2009-07-06 14:52:04 -0700
commitd8b2a6412daef032d89c23e979758f6334b62093 (patch)
treedba55e2701d88e7bb380604520a230abb16b4b66 /libs/ui/ISurfaceFlingerClient.cpp
parentd719890cab1eec09cbf556a3b86cc02b0f0ef8d7 (diff)
parent03a9a3449af3e0e79e9bbcd87f8057189ab9e151 (diff)
Merge commit 'goog/master_gl' into merge_master_gl
Diffstat (limited to 'libs/ui/ISurfaceFlingerClient.cpp')
-rw-r--r--libs/ui/ISurfaceFlingerClient.cpp11
1 files changed, 3 insertions, 8 deletions
diff --git a/libs/ui/ISurfaceFlingerClient.cpp b/libs/ui/ISurfaceFlingerClient.cpp
index 329bd6e94f0a..51e8422606f9 100644
--- a/libs/ui/ISurfaceFlingerClient.cpp
+++ b/libs/ui/ISurfaceFlingerClient.cpp
@@ -64,12 +64,12 @@ public:
{
}
- virtual void getControlBlocks(sp<IMemory>* ctl) const
+ virtual sp<IMemoryHeap> getControlBlock() const
{
Parcel data, reply;
data.writeInterfaceToken(ISurfaceFlingerClient::getInterfaceDescriptor());
remote()->transact(GET_CBLK, data, &reply);
- *ctl = interface_cast<IMemory>(reply.readStrongBinder());
+ return interface_cast<IMemoryHeap>(reply.readStrongBinder());
}
virtual sp<ISurface> createSurface( surface_data_t* params,
@@ -126,8 +126,7 @@ status_t BnSurfaceFlingerClient::onTransact(
switch(code) {
case GET_CBLK: {
CHECK_INTERFACE(ISurfaceFlingerClient, data, reply);
- sp<IMemory> ctl;
- getControlBlocks(&ctl);
+ sp<IMemoryHeap> ctl(getControlBlock());
reply->writeStrongBinder(ctl->asBinder());
return NO_ERROR;
} break;
@@ -192,8 +191,6 @@ status_t ISurfaceFlingerClient::surface_data_t::readFromParcel(const Parcel& par
{
token = parcel.readInt32();
identity = parcel.readInt32();
- heap[0] = interface_cast<IMemoryHeap>(parcel.readStrongBinder());
- heap[1] = interface_cast<IMemoryHeap>(parcel.readStrongBinder());
return NO_ERROR;
}
@@ -201,8 +198,6 @@ status_t ISurfaceFlingerClient::surface_data_t::writeToParcel(Parcel* parcel) co
{
parcel->writeInt32(token);
parcel->writeInt32(identity);
- parcel->writeStrongBinder(heap[0]!=0 ? heap[0]->asBinder() : NULL);
- parcel->writeStrongBinder(heap[1]!=0 ? heap[1]->asBinder() : NULL);
return NO_ERROR;
}