IKScannerDeviceViewDelegate never called
Apparently the following methods are not called:
func scannerDeviceView(IKScannerDeviceView!, didScanTo: ICScannerBandData!, scanInfo: [AnyHashable : Any]!, error: Error!)
func scannerDeviceView(IKScannerDeviceView!, didScanTo: URL!, error: Error!)
Implement the following method instead:
func scannerDeviceView(IKScannerDeviceView!, didScanTo: URL!, fileData: Data!, error: Error!)
Sample Image Capture with Scanner to Yosemite
Regarding that does not recognize your printer Yosemite , try the following
No more scanning after upgrading to MacOS X 10.10
func in swift for self causes error in Xcode
I found the problem. My delegate needs to declare its superclass which is NSObject... like so:
class myDeviceBrowserDelegate : NSObject, ICDeviceBrowserDelegate {
...
Then the self function (among others) was shown as overriding the protocol definition, so I was able to now just delete those functions. Actually, only the two first functions I must declare.
I found this link that helped explain the writing of a delegate in swift: https://medium.com/@agoiabeladeyemi/protocol-in-swift-with-practical-examples-8b955268ce39
Related Topics
Sdwebimage, Swift: Sdwebimagerefreshcached Unresolved Identifier
How to Do Imageview.Startanimating() with Completion in Swift
Swift Equivalent of Objective-C for Flutter Native Ads
Expressions Are Not Allowed at The Top Level
Swift Method Parameters in Documentation
How to Parse Url # Fragments with Query Items in Swift
Swift Loaditem Closure Not Running
How to Get a Full List of Running Processes
Uiview.Animatewithduration Not Animating
Anchor Constraints Not Honored in Xcode 10/iOS 12
Apple Mach-O Linker Error (Static, Not Ld)
Comma Automatically Being Added to Textfield in Swift
Querying Geohashes in Firestore Returns Nothing
Custom Markers Disappear on Zoomin The Map and Appear on Zoomout The Map with Clustering
Swift Combine: Turn a Publisher into a Read-Only Currentvaluesubject
Writing an Enum Case Check to a Bool Variable Without Equatable Conformance
What Is The Reason to Store Subscription into a Subscriptions Set