我需要使用iCarousel iCarouselTypeRotary旋转木马
我目前正在使用从以下链接下载的旋转木马:index=2
它可以在所有模拟器上工作,除了iPhone 4英寸64位刺激器外,它在网上崩溃:
[timer addToRunLoop:[NSRunLoop mainRunLoop] forMode:NSRunLoopCommonModes];上面用iCarousel.m startAnimation函数编写的行以某种方式写入:
#ifdef ICAROUSEL_IOS
#ifndef USING_CHAMELEON
//support for Chameleon
timer = [CADisplayLink displayLinkWithTarget:self selector:@selector(step)];
[timer addToRunLoop:[NSRunLoop mainRunLoop] forMode:NSRunLoopCommonModes];
#endif我没有做任何事情来使用变色龙。
请帮我解决坠机问题。
然后,我尝试从以下位置下载旋转木马文件:
https://github.com/nicklockwood/iCarousel
但不知何故,我无法在iCarouselTypeRotary中做大宽度的点击,所以我只能使用移动tut加,但在iPhone视网膜4英寸64位模拟器中,它正在崩溃。
请帮帮忙。
发布于 2013-11-29 12:37:33
对于任何面临这个问题的人来说:
有时计时器没有在carousel.m文件中分配,该属性被写入如下:
@property (nonatomic, __unsafe_unretained)我们把它改为:
@property (nonatomic, retain)而且,即使在前面的行上分配了它之后,我们也会检查是否存在计时器,如果存在,则只执行addToRunLoop方法。
现在起作用了。
https://stackoverflow.com/questions/20285418
复制相似问题