[android-developers] Re: SeekBar problem
Ok I've been able to obtain the slider update with this funny trick: seekTime.setOnSeekBarChangeListener(new OnSeekBarChangeListener() { public void onStopTrackingTouch(SeekBar seekBar) { final int progress = seekBar.getProgress(); seekBar.setMax(progress * 2); *seekBar.setProgress(progress+1);* * **seekBar.setProgress(progress-1);* } [...] If i just do a setProgress(progress) it have no effect because it probably recognize the same value and think that nothing is to update. I hope this will help somebody in the future. Roberto Previdi -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] SeekBar problem
Hello list.I would like to know why this code don't work: seekTime.setOnSeekBarChangeListener(new OnSeekBarChangeListener() { public void onStopTrackingTouch(SeekBar seekBar) { seekBar.setMax(seekBar.getProgress() * 2); } [...] I'm sure that the function get called because i tried to set a breakpoint. After the execution the mMax member value is correctly changed, the mProgress don't change, but the graphical bar don't move as it should to reflect the new value (it should go to the center). I tried to add a seekBar.invalidate(); but it don't help.. Roberto Previdi -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en