So I created a glass pane or a custom UIView to handle touches. This glass pane sits on top of other views such as dummy UIButtons. When I set the alpha to be 0, the touches actually get intercepted by the views underneath the glass view. This is wrong. However, when I set the alpha to a low value like 0.2, the glass pane intercepts the touches.
The alpha setting was done in Interface Builder.
Anybody know how to set to the alpha to 0 and still get have this glass pane intercept touches?
Yes, it is standard behaviour.
For example, you can just set clear background of that UIView
:
UIView *touchHandlerView;
touchHandlerView.backgroundColor = [UIColor clearColor];
In such case user wouldn't see that view - I assume that you want to do exactly that?
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