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

Commit 94386cd4 authored by Likai Ding's avatar Likai Ding Committed by Gerrit - the friendly Code Review server
Browse files

Gallery: fix lock/unlock order

Fix lock/unlock order to prevent ANR.

Change-Id: I08cee044f9ba10461a276ab2b8af877f821324f4
CRs-Fixed: 1011429
parent 8788884b
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -69,12 +69,12 @@ public class PreparePageFadeoutTexture implements OnGLIdleListener {
        if (task.isCancelled()) return;
        GLRoot root = activity.getGLRoot();
        RawTexture texture = null;
        root.unlockRenderThread();
        root.lockRenderThread();
        try {
            root.addOnGLIdleListener(task);
            texture = task.get();
        } finally {
            root.lockRenderThread();
            root.unlockRenderThread();
        }

        if (texture == null) {