문제

I am wondering how to check if a view's center is in the frame of another UIView? Example: if I have a circle which can be dragged by your finger and it's center point gets dragged to a square's frame some code gets executed? Thanks in advance, Best regards!

도움이 되었습니까?

해결책

You should have a look at Apple's CGGeometry Reference. In particular, you could use CGRectContainsPoint.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top