zoukankan      html  css  js  c++  java
  • UIImagePickerController crash in iOS6, iPhone4S

    The preferredInterfaceOrientationForPresentation method will rotate your view to whatever you set it to when a view is loaded. Be careful as when you come back to your view it may be upside down. Do not include this method if you don’t want it to override the current orientation when you dismiss say a UIImagePickerController.

    UIImagePickerController crash

     Crash:

    Terminating app due to uncaught exception ‘UIApplicationInvalidInterfaceOrientation’, reason: ‘Supported orientations has no common orientation with the application, and shouldAutorotate is returning YES’

     Add to app delegate:

    - (NSUInteger)application:(UIApplication *)application supportedInterfaceOrientationsForWindow:(UIWindow *)w {

    return (NSUInteger)[application supportedInterfaceOrientationsForWindow:w] | (1<<UIInterfaceOrientationPortrait);

    }

  • 相关阅读:
    git merge
    google platform
    http tutorial
    DS,AA tree
    Java,Hashtable
    java,Object
    Pumping lemma for regular languages
    Pumping lemma
    Context-free grammar
    Formal language
  • 原文地址:https://www.cnblogs.com/easonoutlook/p/3083026.html
Copyright © 2011-2022 走看看