Commit 15fb6298 authored by Geoffrey Métais's avatar Geoffrey Métais

Do not hide overlay on pause

parent a72f9b3f
......@@ -759,7 +759,7 @@ public class VideoPlayerActivity extends Activity implements IVideoPlayer {
@Override
public boolean onKeyDown(int keyCode, KeyEvent event) {
showOverlay(OVERLAY_TIMEOUT);
showOverlay();
switch (keyCode) {
case KeyEvent.KEYCODE_F:
case KeyEvent.KEYCODE_MEDIA_FAST_FORWARD:
......@@ -1713,11 +1713,13 @@ public class VideoPlayerActivity extends Activity implements IVideoPlayer {
};
private final void doPlayPause() {
if (mLibVLC.isPlaying())
if (mLibVLC.isPlaying()){
pause();
else
showOverlay(OVERLAY_INFINITE);
} else {
play();
showOverlay();
showOverlay(OVERLAY_TIMEOUT);
}
}
/**
......@@ -1870,7 +1872,7 @@ public class VideoPlayerActivity extends Activity implements IVideoPlayer {
* show overlay the the default timeout
*/
private void showOverlay() {
showOverlay(OVERLAY_TIMEOUT);
showOverlay(mLibVLC.isPlaying() ? OVERLAY_TIMEOUT : OVERLAY_INFINITE);
}
@TargetApi(Build.VERSION_CODES.HONEYCOMB)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment