0

So I am using the video_player package in my Flutter project and have made use of VideoProgressIndicator and it works exactly as intended:

Widget progBar(BuildContext context) {
  return VideoProgressIndicator(
    _controller,
    allowScrubbing: true, // user can touch/drag bar to change position of video.
    colors: VideoProgressColors(playedColor: Colors.red, bufferedColor: Colors.white),
    padding: const EdgeInsets.symmetric(vertical: 6, horizontal: 9),
  );
}

The issue:

I have the timestamp(s) of the video as part of the player and when the user uses the VideoProgressIndicator to change the position of the video, I don't have the new position of the video so that I can update the timestamp(s).

My question:

How can I get the new position of the video when the VideoProgressIndicator changes it?

Thank You!

1 Answer 1

0

Ok so I figured out my solution to be simply to create a custom progress bar that manipulates a timer.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.