title: How to fix statusbar alignment issue for iOS 6 -> iOS 7 transition?
body: <p>Apple's <a href="https://developer.apple.com/library/ios/qa/qa1797/_index.html" rel="nofollow noreferrer">technote here</a> shows their recommend approach for moving content from beneath the iOS 7 status bar to below it (to avoid overlap). However, this technote seems to assume the use of storyboards. I'm wondering what to do if you have a legacy project that has a "View" in an .xib file... not even with a ViewController in the .xib. Just a view. Because you can't visually add constraints unless there is ALSO a ViewController in the .xib. But adding a ViewController results in an uncaught exception at runtime (see below).</p>
  
  <p>To illustrate, rather than try to post all the sample code I think you might need to see from my project, you can duplicate the issue I'm having by launching XCode 4.6.x and choosing New Project. Choose "Single View project" in the iOS category, and <em>uncheck</em> "Use Storyboards".</p>
  
  <p>After creating the project, click on the .xib file. Add a UIViewController so it, setting the existing view as a child of the ViewController. Select the ViewController, show Utilities, and click on the Identity Inspector. There, type in "ViewController" as your class. (So your new UIViewController uses the existing source code.)</p>
  
  <p>When you run, you'll get this error:</p>
  
  <p>*** Terminating app due to uncaught exception 'UIViewControllerHierarchyInconsistency', reason: 'A view can only be associated with at most one view controller at a time! View > is associated with . Clear this association before associating this view with .'</p>
  
  <p><strong>My Question:</strong> Is there any way to add a ViewController to an existing .xib file, so I can add constraints, but not get the runtime exception seen above? </p>
  
  <p>(If you look at the accepted answer <a href="https://stackoverflow.com/questions/12434937/uiviewcontrollerhierarchyinconsistency-when-trying-to-present-a-modal-view-contr">here</a>, it seems the answer may be "no"?)</p>