MSCircularSlider icon indicating copy to clipboard operation
MSCircularSlider copied to clipboard

Provide option to not recognize tap gesture

Open ghost opened this issue 6 years ago • 4 comments

This is a great component! Kudos. Can I request a feature: Add a config option to turn off installing the tap gesture, while only using the slider gesture.

I have a button in the middle of the circular slider and the tap to press the button can often change the slider value without meaning to due to fat fingers :-)

Thanks g

ghost avatar Jan 14 '19 06:01 ghost

Absolutely! This should be fairly straightforward, so I'll probably be adding that feature very soon.

ThunderStruct avatar Jan 14 '19 16:01 ThunderStruct

Apologies for the late reply! I've been swamped with other work for the past few months.

If you somehow remember what the issue was exactly, could you please clarify? I'm preparing an update and your request was on the top of my list. However, I checked the code and tested it myself and it's ignoring taps by default. It would only snap to a different angle if your tap turned into slide (it moves the handle in UIControl's continueTracking() method to be specific).

ThunderStruct avatar Jul 01 '19 11:07 ThunderStruct

I have a semi circular slider with a button in the middle. With a tap, the button can be clicked. but the same tap can sometimes set the slider value too. Currently, a tap on the slider will change the value to where the tap landed. If it can be disabled, that'll be fabulous. OR perhaps there's a setting I may have missed? ( I have another small request - filing it as another issue)

ghost avatar Jul 01 '19 14:07 ghost

Well taps are ignored by default. What's probably happening in your case is that when you press that button, it's not just a tap but a very short slide.

I'll try to add a threshold for how long a slide must be before it takes effect, that should overcome the issue! :-)

ThunderStruct avatar Jul 01 '19 14:07 ThunderStruct