diff options
author | Arun Kumar K.R <akkr@codeaurora.org> | 2012-03-16 19:18:01 -0700 |
---|---|---|
committer | Giulio Cervera <giulio.cervera@gmail.com> | 2012-05-02 12:47:00 +0200 |
commit | b302db6f9a3ee89e48827812278d1425e82f2fdc (patch) | |
tree | 6a05e5c3e4b369c84c525e0f12dbdb701bff9908 /libs | |
parent | 3f4a58e817e291c1ca01f5ff6f297a9123e49173 (diff) | |
download | frameworks_base-b302db6f9a3ee89e48827812278d1425e82f2fdc.zip frameworks_base-b302db6f9a3ee89e48827812278d1425e82f2fdc.tar.gz frameworks_base-b302db6f9a3ee89e48827812278d1425e82f2fdc.tar.bz2 |
SurfaceFlinger: Handle WFD and HDMI concurrency.
- changes to handle wifi display and HDMI concurrency
- rename enableHDMIOutput to enableExternalDisplay
- remove action safe related functions(not used anymore)
Change-Id: I15feb1309c2964de3deb968c334eb09e742afb6c
Diffstat (limited to 'libs')
-rw-r--r-- | libs/gui/ISurfaceComposer.cpp | 36 | ||||
-rw-r--r-- | libs/gui/SurfaceComposerClient.cpp | 14 |
2 files changed, 8 insertions, 42 deletions
diff --git a/libs/gui/ISurfaceComposer.cpp b/libs/gui/ISurfaceComposer.cpp index c0bdb08..1b18d4f 100644 --- a/libs/gui/ISurfaceComposer.cpp +++ b/libs/gui/ISurfaceComposer.cpp @@ -176,28 +176,13 @@ public: } #ifdef QCOM_HDMI_OUT - virtual void enableHDMIOutput(int enable) + virtual void enableExternalDisplay(int disp_type, int enable) { Parcel data, reply; data.writeInterfaceToken(ISurfaceComposer::getInterfaceDescriptor()); + data.writeInt32(disp_type); data.writeInt32(enable); - remote()->transact(BnSurfaceComposer::ENABLE_HDMI_OUTPUT, data, &reply); - } - - virtual void setActionSafeWidthRatio(float asWidthRatio) - { - Parcel data, reply; - data.writeInterfaceToken(ISurfaceComposer::getInterfaceDescriptor()); - data.writeFloat(asWidthRatio); - remote()->transact(BnSurfaceComposer::SET_ACTIONSAFE_WIDTH_RATIO, data, &reply); - } - - virtual void setActionSafeHeightRatio(float asHeightRatio) - { - Parcel data, reply; - data.writeInterfaceToken(ISurfaceComposer::getInterfaceDescriptor()); - data.writeFloat(asHeightRatio); - remote()->transact(BnSurfaceComposer::SET_ACTIONSAFE_HEIGHT_RATIO, data, &reply); + remote()->transact(BnSurfaceComposer::EXTERNAL_DISPLAY, data, &reply); } #endif @@ -282,20 +267,11 @@ status_t BnSurfaceComposer::onTransact( reply->writeInt32(result); } break; #ifdef QCOM_HDMI_OUT - case ENABLE_HDMI_OUTPUT: { + case EXTERNAL_DISPLAY: { CHECK_INTERFACE(ISurfaceComposer, data, reply); + int disp_type = data.readInt32(); int enable = data.readInt32(); - enableHDMIOutput(enable); - } break; - case SET_ACTIONSAFE_WIDTH_RATIO: { - CHECK_INTERFACE(ISurfaceComposer, data, reply); - float asWidthRatio = data.readFloat(); - setActionSafeWidthRatio(asWidthRatio); - } break; - case SET_ACTIONSAFE_HEIGHT_RATIO: { - CHECK_INTERFACE(ISurfaceComposer, data, reply); - float asHeightRatio = data.readFloat(); - setActionSafeHeightRatio(asHeightRatio); + enableExternalDisplay(disp_type, enable); } break; #endif default: diff --git a/libs/gui/SurfaceComposerClient.cpp b/libs/gui/SurfaceComposerClient.cpp index 6264395..4e570e8 100644 --- a/libs/gui/SurfaceComposerClient.cpp +++ b/libs/gui/SurfaceComposerClient.cpp @@ -281,20 +281,10 @@ status_t Composer::setFreezeTint(const sp<SurfaceComposerClient>& client, } #ifdef QCOM_HDMI_OUT -void SurfaceComposerClient::enableHDMIOutput(int enable) +void SurfaceComposerClient::enableExternalDisplay(int disp_type, int enable) { sp<ISurfaceComposer> sm(getComposerService()); - return sm->enableHDMIOutput(enable); -} - -void SurfaceComposerClient::setActionSafeWidthRatio(float asWidthRatio){ - sp<ISurfaceComposer> sm(getComposerService()); - return sm->setActionSafeWidthRatio(asWidthRatio); -} - -void SurfaceComposerClient::setActionSafeHeightRatio(float asHeightRatio){ - sp<ISurfaceComposer> sm(getComposerService()); - return sm->setActionSafeHeightRatio(asHeightRatio); + return sm->enableExternalDisplay(disp_type, enable); } #endif |