如何检测实际View是否来自Storyboard中的源或目标ViewController?
答案 0 :(得分:0)
如果我理解正确,您可以通过以下方式测试questionedView
:
if( [questionedView isDescendantOfView:[storyboardSegue sourceViewController].view] )
{
// view is from sourceViewController
}
和
if( [questionedView isDescendantOfView:[storyboardSegue destinationViewController].view] )
{
// view is from destinationViewController
}