首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >与iOS 5.0 - objectAtIndexedSubscript一起发布的Aviary

与iOS 5.0 - objectAtIndexedSubscript一起发布的Aviary
EN

Stack Overflow用户
提问于 2013-04-01 00:04:15
回答 2查看 549关注 0票数 0

我已经下载了最新的Aviary代码2.6.0,并将其合并到我的Xcode 4.2中,用于运行iPhone 5.0的iOS 4S。每次我启动“航空行动”时,我都会在下面看到objectAtIndexedSubscript的回溯节目。

我看到了这个帖子“Is objectAtIndexedSubscript available in IOS5?”,在iOS 5.0中没有objectAtIndexedSubscript。在Aviary文档中,它说支持iOS 5.0。我错过了什么?

这是我的问题。是否有人试图将最新版本2.6.0用于iOS 5.0的Aviary代码集成?如果不是,那么Aviary版本适用于iOS 5.0吗?在哪里可以下载更早版本的Aviary。我只是还没有准备好转到iOS 6.0。我正试图把这个bug报告给Aviary支持部门,但是我觉得他们会告诉我升级到iOS 6.0。

来自“航空”网站:

运行时要求SDK支持的最低iOS版本是iOS 5.0。这一选择的主要原因是我们使用了ARC (自动参考计数),以及我们对许多需要iOS 5的苹果框架和库的依赖。“

代码语言:javascript
复制
- (void) launchPhotoEditorWithImage:(UIImage *)editingResImage highResolutionImage:(UIImage *)highResImage
{    

    NSLog(@"launchPhotoEditorWithImage ...");

    // Initialize the photo editor and set its delegate
    AFPhotoEditorController * photoEditor = [[AFPhotoEditorController alloc] initWithImage:editingResImage];
    [photoEditor setDelegate:self];

    NSLog(@"Present photo editor ...");

    // Present the photo editor.
    [self presentViewController:photoEditor animated:YES completion:nil];
}

2013-03-31 19:32:14.953 Photo Editor[348:707] launchPhotoEditorWithImage ...
2013-03-31 19:32:15.421 Photo Editor[348:707] Present photo editor ...
2013-03-31 19:32:15.421 Photo Editor[348:3f03] -[__NSArrayM objectAtIndexedSubscript:]: unrecognized selector sent to instance 0x4ac5f0
2013-03-31 19:32:15.432 Photo Editor[348:3f03] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__NSArrayM objectAtIndexedSubscript:]: unrecognized selector sent to instance 0x4ac5f0'
*** First throw call stack:
(0x36fbe8bf 0x3232e1e5 0x36fc1acb 0x36fc0945 0x36f1b680 0xb1a45 0x32933d55 0x32935dc7 0x32935c5d 0x32936867 0x37f5c1cf 0x37f5c0a4)
terminate called throwing an exception[Switching to process 9987 thread 0x2703]
[Switching to process 9987 thread 0x2703]
warning: Attempting to create USE_BLOCK_IN_FRAME variable with block that isn't in the frame.
kill
Current language:  auto; currently objective-c
quit
Program ended with exit code: 0
EN

回答 2

Stack Overflow用户

回答已采纳

发布于 2013-04-01 01:24:43

添加这个家伙类别(从github链接获得),它将完美地工作。

http://cocoaisland.wordpress.com/2012/08/12/modern-objective-c-part-ii-container-subscripting/

票数 0
EN

Stack Overflow用户

发布于 2013-04-01 02:05:39

只需更新到最新的Xcode。在一些旧版本的Xcode中,objectAtIndexedSubscript:不是在SDK中实现的。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/15735998

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档