diff --git a/include/gui/Surface.h b/include/gui/Surface.h index 6f2d40fc5..2288fe775 100644 --- a/include/gui/Surface.h +++ b/include/gui/Surface.h @@ -65,7 +65,7 @@ public: status_t setPosition(int32_t x, int32_t y); status_t setSize(uint32_t w, uint32_t h); status_t hide(); - status_t show(int32_t layer = -1); + status_t show(); status_t setFlags(uint32_t flags, uint32_t mask); status_t setTransparentRegionHint(const Region& transparent); status_t setAlpha(float alpha=1.0f); diff --git a/include/gui/SurfaceComposerClient.h b/include/gui/SurfaceComposerClient.h index 15a0c1eec..295e7fb7d 100644 --- a/include/gui/SurfaceComposerClient.h +++ b/include/gui/SurfaceComposerClient.h @@ -100,7 +100,7 @@ public: static void closeGlobalTransaction(bool synchronous = false); status_t hide(SurfaceID id); - status_t show(SurfaceID id, int32_t layer = -1); + status_t show(SurfaceID id); status_t setFlags(SurfaceID id, uint32_t flags, uint32_t mask); status_t setTransparentRegionHint(SurfaceID id, const Region& transparent); status_t setLayer(SurfaceID id, int32_t layer); diff --git a/libs/gui/Surface.cpp b/libs/gui/Surface.cpp index 33cc48023..174506107 100644 --- a/libs/gui/Surface.cpp +++ b/libs/gui/Surface.cpp @@ -122,11 +122,11 @@ status_t SurfaceControl::hide() { const sp& client(mClient); return client->hide(mToken); } -status_t SurfaceControl::show(int32_t layer) { +status_t SurfaceControl::show() { status_t err = validate(); if (err < 0) return err; const sp& client(mClient); - return client->show(mToken, layer); + return client->show(mToken); } status_t SurfaceControl::setFlags(uint32_t flags, uint32_t mask) { status_t err = validate(); diff --git a/libs/gui/SurfaceComposerClient.cpp b/libs/gui/SurfaceComposerClient.cpp index 1b81e45da..d55d42e9b 100644 --- a/libs/gui/SurfaceComposerClient.cpp +++ b/libs/gui/SurfaceComposerClient.cpp @@ -479,7 +479,7 @@ status_t SurfaceComposerClient::hide(SurfaceID id) { layer_state_t::eLayerHidden); } -status_t SurfaceComposerClient::show(SurfaceID id, int32_t) { +status_t SurfaceComposerClient::show(SurfaceID id) { return getComposer().setFlags(this, id, 0, layer_state_t::eLayerHidden);