DVSwitch
DVSwitch copied to clipboard
Doesn't expose selectedIndex property
Hi there,
This looks pretty nice for a custom control. However, it doesn't appear to be possible to query the current state of the control since the selectedIndex
property is private... I would imagine this would be required by a lot of users.
Pardon me if I'm missing something in the API, but have doesn't seem so to me. In any case, keep up the good work.
Well the intent is that you always control what happens in the pressedHandler block and don't ever need to check the control outside. But I can see when this might be useful.
I second this. Maybe not all the logic code can be put in the pressedBlock. Try to think over this scenario. Also, we may need title of the selected segment.
@ooopscc @itsthejb this property will be made public in next release.
:+1:
:+1: What about the title of the selected segment like UISegmentedControl does?