[Android] LibVLC: AWindow: change surface callback calling order

Thomas Guillem git at videolan.org
Fri May 27 11:02:46 CEST 2016


vlc-android | branch: master | Thomas Guillem <thomas at gllm.fr> | Fri May 27 10:58:54 2016 +0200| [5cac306e7d6ba468d4d6e91b602f0060be343cb2] | committer: Thomas Guillem

LibVLC: AWindow: change surface callback calling order

> https://code.videolan.org/videolan/vlc-android/commit/5cac306e7d6ba468d4d6e91b602f0060be343cb2
---

 libvlc/src/org/videolan/libvlc/AWindow.java | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/libvlc/src/org/videolan/libvlc/AWindow.java b/libvlc/src/org/videolan/libvlc/AWindow.java
index a3fc6ed..1750b73 100644
--- a/libvlc/src/org/videolan/libvlc/AWindow.java
+++ b/libvlc/src/org/videolan/libvlc/AWindow.java
@@ -338,10 +338,10 @@ public class AWindow implements IVLCVout {
                 surfaceHelper.release();
             mSurfaceHelpers[id] = null;
         }
-        if (mSurfaceCallback != null)
-            mSurfaceCallback.onSurfacesDestroyed(this);
         for (IVLCVout.Callback cb : mIVLCVoutCallbacks)
             cb.onSurfacesDestroyed(this);
+        if (mSurfaceCallback != null)
+            mSurfaceCallback.onSurfacesDestroyed(this);
     }
 
     @Override
@@ -362,10 +362,10 @@ public class AWindow implements IVLCVout {
 
         if (videoHelper.isReady() && (subtitlesHelper == null || subtitlesHelper.isReady())) {
             mSurfacesState.set(SURFACE_STATE_READY);
-            if (mSurfaceCallback != null)
-                mSurfaceCallback.onSurfacesCreated(this);
             for (IVLCVout.Callback cb : mIVLCVoutCallbacks)
                 cb.onSurfacesCreated(this);
+            if (mSurfaceCallback != null)
+                mSurfaceCallback.onSurfacesCreated(this);
         }
     }
 



More information about the Android mailing list