mirror of
https://github.com/antebudimir/tempus.git
synced 2025-12-31 09:33:33 +00:00
Try exoplayer reload on player error
This commit is contained in:
parent
a6ef60a0e7
commit
7e2ba5a71a
1 changed files with 3 additions and 0 deletions
|
|
@ -72,6 +72,9 @@ public class MultiPlayer implements Playback {
|
|||
public void onPlayerError(ExoPlaybackException error) {
|
||||
Log.i(TAG, String.format("onPlayerError: %s", error.getMessage()));
|
||||
Toast.makeText(context, context.getResources().getString(R.string.unplayable_file), Toast.LENGTH_SHORT).show();
|
||||
|
||||
exoPlayer.clearMediaItems();
|
||||
exoPlayer.prepare();
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue