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

Commit 6c6fab23 authored by John Reck's avatar John Reck Committed by Android Partner Code Review
Browse files

Merge "Fix setSurfaceTexture to handle surface caching" into m-wireless-dev

parents 36e34886 fd69e2a2
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -723,6 +723,12 @@ public class TextureView extends View {
            mSurface.release();
        }
        mSurface = surfaceTexture;

        // If the view is visible, update the listener in the new surface to use
        // the existing listener in the view.
        if (((mViewFlags & VISIBILITY_MASK) == VISIBLE)) {
            mSurface.setOnFrameAvailableListener(mUpdateListener, mAttachInfo.mHandler);
        }
        mUpdateSurface = true;
        invalidateParentIfNeeded();
    }