From 2a0d5b608447a880beff5149805425f02691442b Mon Sep 17 00:00:00 2001 From: Jamie Gennis Date: Mon, 26 Sep 2011 16:54:44 -0700 Subject: [PATCH] SurfaceFlinger: fix setting default buffer size This change makes SurfaceFlinger update a SurfaceTextureLayer's default buffer size in response to a window resize even if the Layer is in fixed size mode. Change-Id: I3871c8f19a045d03904d1284390cad7659be71ff Bug: 5366426 --- services/surfaceflinger/Layer.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/services/surfaceflinger/Layer.cpp b/services/surfaceflinger/Layer.cpp index edbc7b023..3eaaf82a5 100644 --- a/services/surfaceflinger/Layer.cpp +++ b/services/surfaceflinger/Layer.cpp @@ -371,11 +371,12 @@ uint32_t Layer::doTransaction(uint32_t flags) Layer::State& editDraw(mDrawingState); editDraw.requested_w = temp.requested_w; editDraw.requested_h = temp.requested_h; - - // record the new size, form this point on, when the client request - // a buffer, it'll get the new size. - mSurfaceTexture->setDefaultBufferSize(temp.requested_w, temp.requested_h); } + + // record the new size, form this point on, when the client request + // a buffer, it'll get the new size. + mSurfaceTexture->setDefaultBufferSize(temp.requested_w, + temp.requested_h); } if (temp.sequence != front.sequence) {