문제

If starting a new project in Xcode 4.6 and when adding a button in a ViewController it is always followed by constraints. I have found that this project does not run on the iPhone 5 simulator (iOS5). On iPhone 6 simulator it runs ok. It is the constraints causing the crash. Removing the button and it runs ok on both 5 and 6 simulator. If I use an older Xcode (before the constraints) to start the project and continue with Xcode 4.6 the constraint are gone. But is there a way to disable the constraints from start in Xcode 4.6 to make a project run also with iOS5?

도움이 되었습니까?

해결책

you just need to go file inspector tab where will find the autolayout , then uncheck this. enter image description here

다른 팁

Yeah that's called Auto Layout and was introduced in iOS 6.0 (and like any feature that's unsupported in a previous version of iOS, it crashes).

To disable Auto Layout on your nib file, see this blog article.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top