A-GUIDE-TO-iOS-ANIMATION icon indicating copy to clipboard operation
A-GUIDE-TO-iOS-ANIMATION copied to clipboard

DownloadButton 动画问题

Open 1xiaocainiao opened this issue 9 years ago • 1 comments

您好,感谢分享这么好的demo,发现一个问题,当开始进度条动画的时候,快速点击触发tap事件,会报错<Error>: Error: this application, or a library it uses, has passed an invalid numeric value (NaN, or not-a-number) to CoreGraphics API and this value is being ignored.Please fix this problem. 然后动画就彻底失效了,原demo也有这个问题,不知道怎么回事,望解答

1xiaocainiao avatar Dec 02 '15 14:12 1xiaocainiao

@1xiaocainiao 我也遇到这个问题,问题出在 -(void)tapped:(UITapGestureRecognizer *)tapped 中,需要将 originframe 的赋值顺序改为

 -(void)tapped:(UITapGestureRecognizer *)tapped {
  //originframe = self.frame;
  if (animating == YES) {
        return;
    }
   originframe = self.frame;
  ....
}

liwenDeng avatar May 12 '16 09:05 liwenDeng