oli107 / material-range-bar

Android widget for selecting a range of values.
Apache License 2.0
1.68k stars 370 forks source link

onTouchEnded called when setting pin ranges programmatically #191

Open cirnoftw opened 4 years ago

cirnoftw commented 4 years ago

Just found the source of all phantom onTouchEnded calls I had, and it's in the commit in #162, which adds onTouchEnded call to every setRangePinsByValue call. Any reason why we even need this? It triggers every time value range is set, and that's kind of a problem because I use onTouchEnded listener to distinguish user-made changes from programmatic value updates, but I can't use it because onTouchEnded is called on every value update no matter the source. It's the only setter method that calls this listener for no apparent reason.