简体   繁体   English

xcode-我的应用程序引用的xib文件不存在

[英]xcode - my app is referencing a xib file that is not there

I was given a project half way down. 我得到了一个项目的一半。 The app is in a storyboard, when I run the app I goto a scene and I see elements in the app that I do not see in my scene: 该应用程序位于情节提要中,当我运行该应用程序时,我转到一个场景,并且看到该应用程序中在场景中看不到的元素:

在此处输入图片说明

when I look at the scenes header file, I can see my elements reference a .xib file: 当我查看场景头文件时,可以看到我的元素引用了一个.xib文件:

在此处输入图片说明

When I look in XIB files, that file is not there: 当我查看XIB文件时,该文件不存在:

在此处输入图片说明

But all the elements and buttons work in my app....this is very strange. 但是所有元素和按钮都可以在我的应用中使用。...这很奇怪。 I am able to click on the xib file and it opens, but I cant find anywhere else and if I change something in the xib file, then it does not change in my app. 我可以单击xib文件并打开,但是找不到其他地方,如果我更改了xib文件中的内容,则它在我的应用程序中不会更改。

XIB可能存在于文件系统上,但可能尚未添加到Xcode项目或目标中,或者更有可能在某个时候从项目或目标中删除了-请尝试在文件系统中查找并将其添加到Xcode中,然后查看如果这可以解决问题,或者可以在Xcode中找到它,然后将其添加到构建目标中-如果它已经存在于目标中,则不是,除非您执行干净的构建,否则已编译的NIB将保留下来,因此应用将继续工作正常,但由于未编译/打包XIB,更改不会传播到应用程序中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM