yeahdongcn / RSBarcodes_Swift

1D and 2D barcodes reader and generators for iOS 8 with delightful controls. Now Swift.
MIT License
708 stars 185 forks source link

Type 'UIApplication' has no member 'NSNotification' #125

Closed JLApp2 closed 5 years ago

JLApp2 commented 5 years ago

Hi there, I have the following issues: Type 'UIApplication' has no member 'NSNotification'. Any help would greatly appreciated. Najib

yeahdongcn commented 5 years ago

Could you please show me your code?

JLApp2 commented 5 years ago
rsb

I have tried in other versions of simulators.

JLApp2 commented 5 years ago

My Xcode Version is: 10.1 (10B61) and Swift version is: 4.2.1.

JLApp2 commented 5 years ago

The issue resolved by updating to Swift 4.2. I Write in pod.file: pod 'RSBarcodes_Swift', '~> 4.2'

yeahdongcn commented 5 years ago

Sounds good.

tibm commented 5 years ago

@JLApp2 This should be using the latest Swift changes:

UIApplication.willEnterForegroundNotification and UIApplication.didEnterBackgroundNotification were renamed to NSNotification.Name.UIApplicationWillEnterForeground and NSNotification.Name.UIApplicationDidEnterBackground