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

Commit fd3cee13 authored by John Reck's avatar John Reck
Browse files

Make surfaceRedrawNeeded forgiving

Fixes: 27071678

It's semi-common for apps to not realize surfaceRedrawNeeded
is a callback they can (and should) be handling, so have it be
more tolerant in lifecycle handling.

Specifically allow a renderer to have not yet been set on
GLSurfaceView, even though it was supposed to have been set already.
Apps are overriding the other lifecycle methods that require this
(created, changed, an destroyed) but not noticing this method.

Change-Id: I6cebca541eeec6e9949bdb55f687b095768a17b2
parent 7d0b8d79
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -547,8 +547,10 @@ public class GLSurfaceView extends SurfaceView implements SurfaceHolder.Callback
     */
    @Override
    public void surfaceRedrawNeeded(SurfaceHolder holder) {
        if (mGLThread != null) {
            mGLThread.requestRenderAndWait();
        }
    }


    /**