It's ok. I solved it myself. I just created method that will call setProgress(getMax() - (getMax() - progress)) inside my custom class that extended Seekbar. Cheers
On Oct 11, 6:07 pm, NikolaMKD <[email protected]> wrote: > I have vertical seekbar. > > In the class which extends Seekbar I have on touch listener > @Override > public boolean onTouchEvent(MotionEvent event) { > if (!isEnabled()) { > return false; > } > > switch (event.getAction()) { > case MotionEvent.ACTION_DOWN: > case MotionEvent.ACTION_MOVE: > case MotionEvent.ACTION_UP: > setProgress(getMax() - (int) (getMax() * > event.getY() / getHeight())); > onSizeChanged(getWidth(), getHeight() , 0, 0); > break; > > case MotionEvent.ACTION_CANCEL: > break; > } > return true; > } > > When I setProgress(value) expected output is the progress bar to > change, in my case only yellow surface moves to regular value but the > thumb does not. > > I tried to make it move after setting progress to > setProgress(getMax() - (int) (getMax() * progressDrawableHeight / > getHeight())); > onSizeChanged(getWidth(), getHeight() , 0, 0); > which logically means that the thumb should be moved to progress > drawable height (the edge of the yellow surface) > > Any ideas? -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

