'transparent view with parent view in swift

I have a MyView and top of MyView I have a Transparent View , When I click anywhere on the Transparent View I need to call a function, It is working fine but When I am clicking on the Transparent View where the MyView is the underneath , here my function is not calling ,

I need to call a function anywhere I click on the Transparent View .



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source