How to use Objective-C code with #define macros in Swift

后端 未结 3 1204
后悔当初
后悔当初 2020-12-03 10:00

I\'m trying to use a third-party Objective-C library in a Swift project of mine. I have the library successfully imported into Xcode, and I\'ve made a -

3条回答
  •  北海茫月
    2020-12-03 10:34

    write your constants after Class declaration. like this...

    class ForgotPasswrdViewController: UIViewController {
    let IS_IPHONE5 = fabs(UIScreen.mainScreen().bounds.size.height-568) < 1;
    let Tag_iamTxtf = 101
    

提交回复
热议问题