Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

setProgress(int) method not working. #22

Open
ShabbirK52 opened this issue Dec 8, 2020 · 0 comments
Open

setProgress(int) method not working. #22

ShabbirK52 opened this issue Dec 8, 2020 · 0 comments

Comments

@ShabbirK52
Copy link

ShabbirK52 commented Dec 8, 2020

I am using setProgress(int) method with MediaPlayer. I am trying to update the seek_bar according to the progress of the MediaPlayer but it isn't working and the song lags everytime the Runnable is called.

Runnable runnable = new Runnable() { @Override public void run() { if (mediaPlayer.isPlaying()) { Seek_bar.setProgress(mediaPlayer.getCurrentPosition()); handler.postDelayed(this, 500); } } };

@ShabbirK52 ShabbirK52 changed the title I am using setProgress(int) method with MediaPlayer. I am trying to update the seek_bar according to the progress of the MediaPlayer but it isn't working and the song lags everytime the Runnable is called. setProgress(int) method not working. Dec 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant