How set the duration of 20 second with smooth progress
saadbzu opened this issue · 1 comments
saadbzu commented
It work fine when i use period=50 but when i increase period the progress lose its smoothness.
t.scheduleAtFixedRate(new TimerTask() {
public void run() {
runOnUiThread(new Runnable() {
public void run() {
adCircleProgress5.setAdProgress(i);
i++;
}
});
}
}, 0, 200);
matan-d commented
You might find it better to use:
Handler handler = new Handler(Looper.getMainLooper());
handler.postDelayed(new Runnable(){
@Override
public void run() {
adCircleProgress5.setAdProgress(i);
i++;
}
}, 1000);
But from what I can see, the progress already shows the seconds running (unlike minutes which is static and changes only for each minute)