SBSDKBarcodeTrackingOverlayControllerDelegate
@objc
public protocol SBSDKBarcodeTrackingOverlayControllerDelegate
The delegation protocol for the barcode tracking overlay controller.
-
Called when a barcode is being tapped on.
Declaration
Swift
@objc optional func barcodeTrackingOverlay(_ controller: SBSDKBarcodeTrackingOverlayController, didTapOnBarcode barcode: SBSDKBarcodeScannerResult)
Parameters
controller
The barcode tracking overlay controller that the tracked barcode view belongs to.
barcode
The barcode the user tapped on.
-
Called when the barcode selection has changed. Only called if the barcode tracking overlay controllers configuration has its isSelectable property set to true.
Declaration
Swift
@objc optional func barcodeTrackingOverlay(_ controller: SBSDKBarcodeTrackingOverlayController, didChangeSelectedBarcodes selectedBarcodes: [SBSDKBarcodeScannerResult])
Parameters
controller
The barcode tracking overlay controller that the tracked barcode view belongs to.
selectedBarcodes
The barcodes that are currently selected.
-
Asks the delegate to provide a custom style for a tracked barcodes polygon. Is called when drawing the polygon view for the tracked barcode.
Declaration
Swift
@objc optional func barcodeTrackingOverlay(_ controller: SBSDKBarcodeTrackingOverlayController, polygonStyleFor barcode: SBSDKBarcodeScannerResult) -> SBSDKBarcodeTrackedViewPolygonStyle?
Parameters
controller
The barcode tracking overlay controller that the tracked barcode view belongs to.
barcode
The barcode that should be drawn on the overlay.
Return Value
The polygon style to be used when drawing the polygon for the tracked barcode.
-
Asks the delegate to provide a custom style for a tracked barcodes info view. Is called when drawing the info view for the tracked barcode.
Declaration
Swift
@objc optional func barcodeTrackingOverlay(_ controller: SBSDKBarcodeTrackingOverlayController, textStyleFor barcode: SBSDKBarcodeScannerResult) -> SBSDKBarcodeTrackedViewTextStyle?
Parameters
controller
The barcode tracking overlay controller that the tracked barcode view belongs to.
barcode
The barcode that should be drawn on the overlay.
Return Value
The text style to be used when drawing the polygon for the tracked barcode.