Thomas Clayson
Thomas Clayson

Reputation: 29925

Press a button behind a UIView

I have a button and half of the button is covered by a UIView (for styling).

I was wondering if there was any way to make this UIView "touch transparent" as it were, so if you press on it it lets you select the image behind it?

Or will I just have to make it a button itself?

Thanks

Tom

Upvotes: 0

Views: 260

Answers (2)

jithinroy
jithinroy

Reputation: 1885

try to make the UIView opaque to NO

Upvotes: 0

Cedric Vandendriessche
Cedric Vandendriessche

Reputation: 728

You should set the UIView's userInteractionEnabled property to NO.

Upvotes: 2

Related Questions