【发布时间】:2010-02-12 15:41:38
【问题描述】:
想实现像Season's Greetinghttp://itunes.apple.com/us/app/seasons-greeting/id345499393?mt=8这样的应用程序
但是当我在 UIScrollView 中添加多个图像视图时出现以下错误:
程序接收信号:“0”警告:check_safe_call:无法恢复当前帧
我已经将图像添加为 .png 文件,并且我也使用过
[[NSBundle mainBundle] pathForResource:[NSString stringWithFormat:@"Template1"]
ofType:@"png"];
UIImage* templateImg = [UIImage imageWithContentsOfFile:templateName];
[templateArray addObject:templateImg];
UIImageView* imgView = [[UIImageView alloc] initwithimage:templateImg];
[scrollView addSubview:imgView];
当我如上所述添加 25 imgView 时,我的应用在 iPhone 模拟器和 iPhone 上崩溃了。
查看崩溃日志,设备似乎在抱怨内存不足。对我来说,显示此行为的代码仅在 3.0 上显示。这在 2.x 上从未发生过,代码完全相同。
【问题讨论】:
标签: iphone