[Android] Simplify logics

Geoffrey Métais git at videolan.org
Mon Jun 27 16:35:18 CEST 2016


vlc-android | branch: 2.0.x | Geoffrey Métais <geoffrey.metais at gmail.com> | Mon Jun 27 16:25:59 2016 +0200| [f3b2101a5ce0a511164f997e21fb49670804b086] | committer: Geoffrey Métais

Simplify logics

(cherry picked from commit e66bf866565772684425b942335e4789bfc5f4dd)

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

 vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
index 4f948bd..d1aefb6 100644
--- a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
+++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
@@ -599,9 +599,7 @@ public class VideoPlayerActivity extends AppCompatActivity implements IVLCVout.C
         mSize.setOnClickListener(null);
 
         /* Stop the earliest possible to avoid vout error */
-        if (isFinishing())
-            stopPlayback();
-        else if (AndroidDevices.isAndroidTv() && Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP && !requestVisibleBehind(true))
+        if (isFinishing() || (AndroidDevices.isAndroidTv() && !requestVisibleBehind(true)))
             stopPlayback();
     }
 



More information about the Android mailing list