After creating a round rect button, i disabled the button and the alpha of the button stays at 1 unless i reduced the alpha to 0.5 manually. But after inserting an image to the button, the alpha of the button would be set to 0.5 automatically even after setting the alpha to 1 after disabling the button.
I would like to disable the button containing an image without affecting it's alpha.
Can anyone Help me?
Regards,
Bob
Have a look at the UIButton
's adjustsImageWhenDisabled
property. Setting that to NO should do what you want.
There's also a similar property for highlighted buttons.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With