我想检查iOS设备的版本是否大于3.1.3
我尝试过的东西:
[[UIDevice currentDevice].systemVersion floatValue]
Run Code Online (Sandbox Code Playgroud)
但它不起作用,我只想要一个:
if (version > 3.1.3) { }
Run Code Online (Sandbox Code Playgroud)
我怎样才能做到这一点?
如何才能在iOS中获得屏幕的尺寸?
目前,我使用:
lCurrentWidth = self.view.frame.size.width;
lCurrentHeight = self.view.frame.size.height;
Run Code Online (Sandbox Code Playgroud)
在viewWillAppear:和willAnimateRotationToInterfaceOrientation:duration:
我第一次得到整个屏幕尺寸.第二次我屏幕减去导航栏.