Swift 宏定义iPhoneX

let iPhoneX = (UIScreen.instanceMethod(for: #selector(getter: UIScreen.main.currentMode)) != nil) ? __CGSizeEqualToSize(CGSize.init(width: 1125, height: 2436), (UIScreen.main.currentMode?.size)!) : false

你可能感兴趣的:(Swift 宏定义iPhoneX)