Commit f983438e authored by Sébastien Toque's avatar Sébastien Toque
Browse files

video: use length stored in the database if vlc doesn't have it yet

parent 519d9dd4
......@@ -1383,6 +1383,11 @@ public class VideoPlayerActivity extends Activity implements IVideoPlayer {
}
int time = (int) mLibVLC.getTime();
int length = (int) mLibVLC.getLength();
if (length == 0) {
Media media = MediaDatabase.getInstance(this).getMedia(this, mLocation);
if (media != null)
length = (int) media.getLength();
}
// Update all view elements
mControls.setSeekable(length > 0);
......
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