您的位置:首页 > 产品设计 > UI/UE

UIDevice的orientation方法,获取ios设备方向不准确问题

2012-11-27 15:33 761 查看
使用 UIDeviceOrientation deviceOrientation = [UIDevice currentDevice].orientation方法,获取当前设备的方向,第一次使用的时候,总是返回0

可以使用 下边这个方法获取,

UIInterfaceOrientation deviceOrientation = [[UIApplication
sharedApplication] statusBarOrientation];
标记一下.
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: