|
|
@ -10,8 +10,6 @@ final class ScanQRCodeWrapperVC: BaseVC {
|
|
|
|
private let message: String?
|
|
|
|
private let message: String?
|
|
|
|
private let scanQRCodeVC = QRCodeScanningViewController()
|
|
|
|
private let scanQRCodeVC = QRCodeScanningViewController()
|
|
|
|
|
|
|
|
|
|
|
|
override var supportedInterfaceOrientations: UIInterfaceOrientationMask { return .portrait }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// MARK: - Lifecycle
|
|
|
|
// MARK: - Lifecycle
|
|
|
|
|
|
|
|
|
|
|
|
init(message: String?) {
|
|
|
|
init(message: String?) {
|
|
|
@ -47,7 +45,7 @@ final class ScanQRCodeWrapperVC: BaseVC {
|
|
|
|
scanQRCodeVCView.autoPinEdge(.top, to: .top, of: view)
|
|
|
|
scanQRCodeVCView.autoPinEdge(.top, to: .top, of: view)
|
|
|
|
|
|
|
|
|
|
|
|
if let message = message {
|
|
|
|
if let message = message {
|
|
|
|
scanQRCodeVCView.autoPinToSquareAspectRatio()
|
|
|
|
scanQRCodeVCView.set(.height, lessThanOrEqualTo: UIScreen.main.bounds.width)
|
|
|
|
|
|
|
|
|
|
|
|
// Set up bottom view
|
|
|
|
// Set up bottom view
|
|
|
|
let bottomView = UIView()
|
|
|
|
let bottomView = UIView()
|
|
|
@ -78,8 +76,6 @@ final class ScanQRCodeWrapperVC: BaseVC {
|
|
|
|
override func viewDidAppear(_ animated: Bool) {
|
|
|
|
override func viewDidAppear(_ animated: Bool) {
|
|
|
|
super.viewDidAppear(animated)
|
|
|
|
super.viewDidAppear(animated)
|
|
|
|
|
|
|
|
|
|
|
|
UIDevice.current.ows_setOrientation(.portrait)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
self.scanQRCodeVC.startCapture()
|
|
|
|
self.scanQRCodeVC.startCapture()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|