-
Notifications
You must be signed in to change notification settings - Fork 228
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug when setting lower and upper bounds in a specific order #66
Comments
Thanks a bunch for posting this. I just spent an hour trying to figure out if I was going crazy or not with things working a certain way and not in other instances lol. I did what you said and it's working as expected. Really surprised this isn't a standard iOS control. This is the best one that I found by far because it is styled to look like the other controls on iOS. |
Sorry, I've been meaning to fix this bug for a while! |
First, thanks a lot for this useful component, that should have been a standard control in my opinion, I faced the same problem for several hours, going mad trying to reload the cell containing the control in every moment possible.... :(, but hopefully found this solution xD Special thanks to fmaylinch for finding the good sequence of setting values :) |
this bug is at line 139 of NMRangeSlider.m:
when you set the lowerValue, the default _upperValue has not been set yet, it still 1.0 by default
|
I've created a Pull Request that resolves this issue. Fixed bug when setting lower and upper bounds in a specific order |
Oh my god, thank you for pointing this out, this caused me a huge headache. Thanks for the control @muZZkat ! |
Haha no worries. Just waiting for it to be integrated into the master branch. Let me know if it works for you. |
I've seen that there's a bug when setting values like these:
It seems that the setter for
lowerValue
limits the value to currentupperValue
(which is 1.0 by default) solowerValue
ends up being 1.0 too. But since theminimumValue
is 6 you get a wrong slider.It works if I set the values in this order:
The text was updated successfully, but these errors were encountered: