ios 监听设备旋转方向
-(void)didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation { if(fromInterfaceOrientation == UIInterfaceOrientationLandscapeLeft || fromInterfaceOrientation == UIInterfaceOrientationLandscapeRight) { }
if (self.interfaceOrientation == UIDeviceOrientationPortrait){
NSLog(@"竖直");
}
elseif(self.interfaceOrientation == UIDeviceOrientationLandscapeLeft)
{
NSLog(@"水平向左");
}
elseif(self.interfaceOrientation == UIDeviceOrientationLandscapeLeft)
{
NSLog(@"水平向左");
}
}
浙公网安备 33010602011771号