You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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); } } };
The text was updated successfully, but these errors were encountered:
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
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); } } };
The text was updated successfully, but these errors were encountered: