1

I have two UIStackViews and they animate so when it is supposed to be tapped the overlapping shouldn't exist or be a problem anymore, but it still is.

Is there a way to still accept touches on a control that's covered by another control? enter image description here

This is how it looks without running it...when it loads..the square stackview in the middle stays put and the other one which is still behind it...grows adn the buttosn aren't covered anymore

1
  • cabn you show a picture of your storyboard or something for better understanding? Commented May 30, 2016 at 7:12

1 Answer 1

1

You can set userInteractionEnabled to false on the covering views

Or if you want both to receive events, set exclusiveTouch to false, and userInteractionEnabled to true.

Sign up to request clarification or add additional context in comments.

5 Comments

but i want them to be interacted upon too
@RubberDucky4444 does it work when you remove the overlapping view? (i.e. it's not a problem with a zero size control somewhere)
I just removed it temporarily and all the afffecting code and the problem is now revealed....it works but only if you tap in one particular spot....even though the button is 100px x 100px
@RubberDucky4444 maybe a container view of the button doesn't have the proper size? You could try the "Debug View Hierarchy" or "Show View Frames" when running it in debug mode, might reveal something?
@RubberDucky4444 no problem, glad you figured it out