Reputation: 3628
I have a bunch of UIButtons mimicking actual arcade-style buttons.
For some reason I remember seeing somewhere that I can have the button use a different image when it is pressed and when it is not pressed. I just can't find it now that I actually need it... think it was somewhere in IB.
I haven't declared them programmatically so if that's where the option lies I'm SOL.
Upvotes: 1
Views: 2585
Reputation: 14791
If you look in the attributes inspector for a button in IB, you'll see a drop-down list labelled "State Config" in the same group as the "Image" attribute. The options in this list are "Default", "Highlighted", "Selected" and "Disabled" - choose one of these, then select an image to set it for that state.
Upvotes: 11