省略了部分系统事件
事件
hitTest-UIWindow
pointInside-UIWindow
pointInside-UIWindow YES
hitTest-UIView
pointInside-UIView
pointInside-UIView YES
hitTest-UIButton
pointInside-UIButton
pointInside-UIButton YES
hitTest-UIButton UIButton
hitTest-UIView UIButton
hitTest-UIWindow UIButton
响应
UIButton
UIView
ViewController
UIWindow
UIApplication
AppDelegate
//hitTest伪代码
:hitTest:view
if pointInside(view) {
for v in view.subView.reverse
var rv = hitTest(v)
if rv return v
}
return nil
网友评论