play method

Future<void> play({
  1. bool repeat = false,
})

play the current video

repeat if is true the player go to Duration.zero before play

Implementation

Future<void> play({bool repeat = false}) async {
  if (repeat) {
    await seekTo(Duration.zero);
  }
  await _videoPlayerController?.play();
  playerStatus.status.value = PlayerStatus.playing;

  _hideTaskControls();
}