[Android] [PATCH] VideoPlayerActivity was checking incorrect View.

Geoffrey Métais geoffrey.metais at gmail.com
Fri Nov 4 14:41:57 CET 2016


LGTM, thx for the contribution :)

On Thu, Nov 3, 2016 at 10:56 PM Evan Leis <evan.explodes at gmail.com> wrote:

> VideoPlayerActivity was checking the wrong view's visibility
> to determine whether or not to apply the subtitle surface to
> the current IVLCVout. This could have led to an NPE.
>
> This not being an NPE is possibly evidence that mPresentation
> is not fully utilized and could possible be removed altogether.
> ---
>  vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> 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 21f42a1..3b83322 100644
> --- a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
> +++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
> @@ -784,7 +784,7 @@ public class VideoPlayerActivity extends
> AppCompatActivity implements IVLCVout.C
>                  vlcVout.setSubtitlesView(mSubtitlesSurfaceView);
>          } else {
>              vlcVout.setVideoView(mPresentation.mSurfaceView);
> -            if (mSubtitlesSurfaceView.getVisibility() != View.GONE)
> +            if (mPresentation.mSubtitlesSurfaceView.getVisibility() !=
> View.GONE)
>
>  vlcVout.setSubtitlesView(mPresentation.mSubtitlesSurfaceView);
>          }
>          vlcVout.addCallback(this);
> --
> 2.7.4
>
> _______________________________________________
> Android mailing list
> Android at videolan.org
> https://mailman.videolan.org/listinfo/android
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/android/attachments/20161104/30f0b37d/attachment.html>


More information about the Android mailing list