呼叫不會進入UIInterfaceOrientation委託方法,請幫助UIInterfaceOrientation方法不靈
這裏是代碼
- (BOOL) shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation
{
return YES;
}
- (void)willRotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)duration
{
if (toInterfaceOrientation == UIInterfaceOrientationPortrait)
{
NSLog(@"potrait");
}
else
{
}
}