I’m creating an application that allows the user to add their own UISwitch and UISegmentedControl controls to the screen. Then they can Manipulate the colors, titles, etc. Though in order for me to ‘select’ them and manipulate them in my Development environment I need to set the user Interaction/enabled to NO. Doing this causes the Controls to ‘dim’ and become a but transparent. I don’t really want that as the Colors of the controls are also dim so the color representation is not correct.
the UIButton has an option: @property(nonatomic) BOOL adjustsImageWhenDisabled
I’d like something like this for UISwitch and UISegmentedControl
Is there a way to make it so a disabled UISwitch and UISegmentedControl is not ‘dimmed’ ?
Thanks,
Scott<-
Not that I know of.
However, you can solve this in a different way 🙂
Add a new transparent UIView over everything and use this to grab your touch events. This would let you keep your UIControls userInteractionEnabled set to YES but the touches would never reach them 🙂