Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 493743e0 authored by Romain Guy's avatar Romain Guy Committed by Android (Google) Code Review
Browse files

Merge "Flip TextureView's layer after calling setSurfaceTexture() Bug #6531172" into jb-dev

parents a6f0b0ad 51f7c6b3
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -374,6 +374,14 @@ public class TextureView extends View {
            // tell mLayer about it and set the SurfaceTexture to use the
            // current view size.
            mUpdateSurface = false;

            // Since we are updating the layer, force an update to ensure its
            // parameters are correct (width, height, transform, etc.)
            synchronized (mLock) {
                mUpdateLayer = true;
            }
            mMatrixChanged = true;

            mAttachInfo.mHardwareRenderer.setSurfaceTexture(mLayer, mSurface);
            nSetDefaultBufferSize(mSurface, getWidth(), getHeight());
        }
@@ -471,7 +479,7 @@ public class TextureView extends View {
    }

    private void applyTransformMatrix() {
        if (mMatrixChanged) {
        if (mMatrixChanged && mLayer != null) {
            mLayer.setTransform(mMatrix);
            mMatrixChanged = false;
        }