【问题标题】:non public selector heightForRow:AtIndex in cocos2d during validation in Xcode 6在 Xcode 6 中验证期间 cocos2d 中的非公共选择器 heightForRow:AtIndex
【发布时间】:2014-11-30 12:32:13
【问题描述】:

最近我已将我的 Xcode 从 v 5.1.1 更新到 6.0.1。在验证我当前的 Cocos2d v3.1 项目期间,iTunes 商店向我显示了警告

iTunes Store operation failed.
The app references non-public selectors in Payload/<AppName>.app/<AppName>:tableView:heightForRowAtIndex:

有没有办法解决这个验证警告?

【问题讨论】:

标签: cocos2d-iphone ios8 xcode6


【解决方案1】:

哦,这是由于 Cocos2d 3.1 库中的 CCTableView 类。在CCTableView.h 中声明的CCTableViewDataSource 中有一个方法名称- (float) tableView:(CCTableView*)tableView heightForRowAtIndex:(NSUInteger) index;。可能这个方法也在其他一些类中声明,CCTableView.m 通过调用[dataSource respondsToSelector:@selector(tableView:heightForRowAtIndex:)]; 来调用这个方法。

我通过在CCTableViewDataSource 中将其声明为-(float) ccTableView:(CCTableView*)tableView heightForRowAtIndex:(NSUInteger) index; 来更改方法名称,并通过将[dataSource respondsToSelector:@selector(tableView:heightForRowAtIndex:)]; 替换为[dataSource respondsToSelector:@selector(ccTableView:heightForRowAtIndex:)]; 并将[_dataSource tableView:self heightForRowAtIndex:i]; 替换为[_dataSource ccTableView:self heightForRowAtIndex:i]; 来更改CCTableView.m 文件中的相应调用。

【讨论】:

  • 酷我也会这样做。让我们希望 Cocos2D 团队也修复它......虽然看起来 ITC 的某些脚本确实有问题......
  • 只是重命名讨论的方法解决了我的问题,iTunes connect 成功验证了我的应用程序。您的应用程序的当前状态是什么?它是否面临来自 iTunes Connect 的相同有效性警告?
  • 是的,这是一个警告/问题,源于缺少命名空间。我重命名了员工,没有发生名称冲突。这是另一个解释这一点的问题/答案:stackoverflow.com/questions/19378484/…
  • 如果我保持这个警告不变,苹果会拒绝应用程序吗?
  • @LocPham 我之前已经提交了带有验证警告的 ipa,Apple 并没有拒绝它。但始终建议解决每个验证警告。
猜你喜欢
  • 2015-06-13
  • 1970-01-01
  • 1970-01-01
  • 2014-12-16
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2015-01-29
  • 1970-01-01
相关资源
最近更新 更多