Skip to content

Commit 3a23212

Browse files
author
Jamie Gennis
committed
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
1 parent 61b645a commit 3a23212

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

services/surfaceflinger/Layer.cpp

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -371,11 +371,12 @@ uint32_t Layer::doTransaction(uint32_t flags)
371371
Layer::State& editDraw(mDrawingState);
372372
editDraw.requested_w = temp.requested_w;
373373
editDraw.requested_h = temp.requested_h;
374-
375-
// record the new size, form this point on, when the client request
376-
// a buffer, it'll get the new size.
377-
mSurfaceTexture->setDefaultBufferSize(temp.requested_w, temp.requested_h);
378374
}
375+
376+
// record the new size, form this point on, when the client request
377+
// a buffer, it'll get the new size.
378+
mSurfaceTexture->setDefaultBufferSize(temp.requested_w,
379+
temp.requested_h);
379380
}
380381

381382
if (temp.sequence != front.sequence) {

0 commit comments

Comments
 (0)