[Android] Code cleaning

Geoffrey Métais git at videolan.org
Tue Dec 26 17:42:34 CET 2017


vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Tue Dec 26 17:32:52 2017 +0100| [96ce387162ef87ad3877e0822b5830bc355a8bcb] | committer: Geoffrey Métais

Code cleaning

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

 .../src/org/videolan/vlc/gui/video/VideoPlayerActivity.java   | 11 ++---------
 1 file changed, 2 insertions(+), 9 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 62c31d4d9..2cf28c5d7 100644
--- a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
+++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
@@ -862,8 +862,6 @@ public class VideoPlayerActivity extends AppCompatActivity implements IVLCVout.C
 
     private void initUI() {
 
-        cleanUI();
-
         /* Dispatch ActionBar touch events to the Activity */
         mActionBarView.setOnTouchListener(new View.OnTouchListener() {
             @Override
@@ -878,8 +876,7 @@ public class VideoPlayerActivity extends AppCompatActivity implements IVLCVout.C
         /* Listen for changes to media routes. */
         mediaRouterAddCallback(true);
 
-        if (mRootView != null)
-            mRootView.setKeepScreenOn(true);
+        if (mRootView != null) mRootView.setKeepScreenOn(true);
     }
 
     private void setPlaybackParameters() {
@@ -946,8 +943,7 @@ public class VideoPlayerActivity extends AppCompatActivity implements IVLCVout.C
     @TargetApi(Build.VERSION_CODES.HONEYCOMB)
     private void cleanUI() {
 
-        if (mRootView != null)
-            mRootView.setKeepScreenOn(false);
+        if (mRootView != null) mRootView.setKeepScreenOn(false);
 
         if (mDetector != null) {
             mDetector.setOnDoubleTapListener(null);
@@ -959,9 +955,6 @@ public class VideoPlayerActivity extends AppCompatActivity implements IVLCVout.C
 
         surfaceFrameAddLayoutListener(false);
 
-        if (AndroidUtil.isICSOrLater)
-            getWindow().getDecorView().setOnSystemUiVisibilityChangeListener(null);
-
         mActionBarView.setOnTouchListener(null);
     }
 



More information about the Android mailing list