委托 – ‘Xcode找不到“UIViewControllerAnimatedTransitioning”的协议声明

委托 – ‘Xcode找不到“UIViewControllerAnimatedTransitioning”的协议声明,第1张

概述我创建了一个抛出错误的vanilla Xcode(v6.2)项目(项目A): ‘Xcode cannot find protocol declaration of “UIViewControllerAnimatedTransitioning”‘ 这是代码: #import <Foundation/Foundation.h>@interface WTF : NSObject <UIViewCon 我创建了一个抛出错误的vanilla Xcode(v6.2)项目(项目A):

‘Xcode cannot find protocol declaration of
“UIVIEwControllerAnimatedTransitioning”‘

这是代码:

#import <Foundation/Foundation.h>@interface WTF : NSObject <UIVIEwControllerAnimatedTransitioning>@end

奇怪的是,我有一个我下载的示例项目(项目B),我可以将上面的代码放入其中,它将识别UIVIEwControllerAnimatedTransitioning协议而没有问题:

#import <Foundation/Foundation.h>@interface WTF : NSObject <UIVIEwControllerAnimatedTransitioning>@end

我注意到两个项目之间最明显的差异是第二个下载的项目具有在资源管理器中列出的框架,但我使用Xcode 6.2创建的项目没有.在进一步阅读后,我发现新版本的Xcode消除了手动连接框架的需要,所以我不确定它是否相关.

因此,如果项目A在项目B没有的事情上抛出错误,我在Xcode(单视图应用程序)中启动了一个新项目(项目C)并粘贴在:

#import <Foundation/Foundation.h>@interface WTF : NSObject <UIVIEwControllerAnimatedTransitioning>@end

并得到相同的错误:

‘Xcode cannot find protocol declaration of
“UIVIEwControllerAnimatedTransitioning”‘

重新启动Xcode和Mac,错误仍然存​​在.

WTF正在这里发生?

解决方法 啊.需要导入
UIKit/UIKit.h

3小时.

总结

以上是内存溢出为你收集整理的委托 – ‘Xcode找不到“UIViewControllerAnimatedTransitioning”的协议声明全部内容,希望文章能够帮你解决委托 – ‘Xcode找不到“UIViewControllerAnimatedTransitioning”的协议声明所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址:https://54852.com/web/1104102.html

(0)
打赏 微信扫一扫微信扫一扫 支付宝扫一扫支付宝扫一扫
上一篇 2022-05-28
下一篇2022-05-28

发表评论

登录后才能评论

评论列表(0条)

    保存