Hi,
Great little library, thanks for your work!
I've replaced some UISliders with your GradientSlider, and noticed that (unlike UISlider), when setting an action/target pair for UIControlEventValueChanged of the form:
- (void)action:(id)sender forEvent:(UIEvent *)event the received event is always nil.
I believe this is due to the calls to sendActions losing the associated UIEvent info, and successfully implemented a fix by replacing them with loops of sendAction calls.
Also - not sure, but I believe the call to sendActions in beginTracking should include valueChanged in its controlEvents to match UISlider behavior.
Let me know if this is at all something you wish to change, I could submit a small PR (tho my swift is weak)
Thanks!
Hi,
Great little library, thanks for your work!
I've replaced some UISliders with your GradientSlider, and noticed that (unlike UISlider), when setting an action/target pair for
UIControlEventValueChangedof the form:- (void)action:(id)sender forEvent:(UIEvent *)eventthe receivedeventis alwaysnil.I believe this is due to the calls to
sendActionslosing the associatedUIEventinfo, and successfully implemented a fix by replacing them with loops ofsendActioncalls.Also - not sure, but I believe the call to
sendActionsinbeginTrackingshould includevalueChangedin its controlEvents to match UISlider behavior.Let me know if this is at all something you wish to change, I could submit a small PR (tho my swift is weak)
Thanks!