I\'ve been reading through the docs, and I cannot figure out how to cancel a \"drag\" on a Seekbar once the bar has been completed.
For example, when I drag the bar
seekBarObj.setOnSeekBarChangeListener(new OnSeekBarChangeListener() {
int originalProgress;
@Override
public void onStopTrackingTouch(SeekBar seekBar) {
}
@Override
public void onStartTrackingTouch(SeekBar seekBar) {
originalProgress = seekBar.getProgress();
}
@Override
public void onProgressChanged(SeekBar seekBar, int arg1, boolean fromUser) {
if(fromUser == true){
seekBar.setProgress(originalProgress);
}
}
});
Try this..it works fine..
mSeekBar.setEnabled(false);