【发布时间】:2015-08-06 06:07:19
【问题描述】:
将我的项目从“apple watch company tutorial”重命名为“Project x”后,我遇到了一些麻烦,我通过查看answer和this one解决了一些问题
iPhone 应用程序 Info.plist:
Bundle identifier: com.company.projectx
Watchkit 扩展 Info.plist:
Bundle identifier: com.company.projectx.watchkitextension
WKAppBundleIdentifier: com.company.projectx.watchkitapp
RemoteInterfacePrincipalClass: com.company.projectx.watchkitextension.InterfaceController
WatchKit 应用信息.plist
Bundle identifier: com.company.projectx.watchkitapp
WKCompanionAppBundleIdentifier: com.company.projectx
我的起始界面被命名为 InterfaceController
但现在我遇到了麻烦
2015-08-05 08:38:21.758 projectx WatchKit Extension[24714:1080879] WatchKit error - unable to find interface controller class '_TtC46Apple_Watch_Company_Tutorial_WatchKit_Extension19InterfaceController' to instantiate
我认为我的问题仍然与重命名项目和手动更改捆绑包有关,但我不知道我做错了什么。
【问题讨论】:
-
它似乎正在尝试在旧名称包中定位接口,请注意这部分
class '_TtC46Apple_Watch_Company_Tutorial_WatchKit_Extension19InterfaceController'仍然包含 Watch_Company_Tutorial。清理项目可能会有所帮助。 -
我跟着这个,它对我有用:) stackoverflow.com/questions/29121727/…
标签: ios swift rename watchkit apple-watch