preferredInterfaceOrientationForpresentation doit retourner une prise en charge de l'interface d'orientation

Cette erreur n'a pas de sens, comme l'orientation préférée UIInterfaceOrientationLandscapeRight est retourné par la pris en charge de l'orientation

//iOS6

-(BOOL)shouldAutorotate
{
    return NO;
}

-(NSUInteger)supportedInterfaceOrientations
{
    return (UIInterfaceOrientationLandscapeRight | UIInterfaceOrientationLandscapeLeft);
}

- (UIInterfaceOrientation)preferredInterfaceOrientationForPresentation
{
    return UIInterfaceOrientationLandscapeRight;
}

Erreur :

Résiliation d'application en raison de uncaught exception
'UIApplicationInvalidInterfaceOrientation', la raison:
'preferredInterfaceOrientationForpresentation doit retourner une prise en charge
l'interface de l'orientation!'

InformationsquelleAutor Peter Lapisu | 2012-10-02