判断当前的机型

[UIDevice currentDevice] model]可以判断机型;

[UIDevice currentDevice] currentMode] 判断屏幕分辨率;




if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad)
    {
        //ipad
    }
    else 
    {
        //other
    }

你可能感兴趣的:(判断当前的机型)