已知button的frame,如果要计算button相对于view的frame,则可以使用以下方法
CGRect rc = [btn.superview convertRect:btn.frame toView:self.view];
转载请标注来源:https://www.cnblogs.com/qqcc1388/p/10617312.html