mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-12-24 14:32:37 +01:00
chore: Follow up fix qr code scanner
This commit is contained in:
parent
f3b8abd504
commit
9ace5d8375
@ -59,6 +59,12 @@ class _QrScannerModalState extends State<QrScannerModal> {
|
|||||||
|
|
||||||
void _onQRViewCreated(QRViewController controller) {
|
void _onQRViewCreated(QRViewController controller) {
|
||||||
this.controller = controller;
|
this.controller = controller;
|
||||||
|
// Workaround for QR Scanner is started in Pause mode
|
||||||
|
// https://github.com/juliuscanute/qr_code_scanner/issues/538#issuecomment-1133883828
|
||||||
|
if (Platform.isAndroid) {
|
||||||
|
controller.pauseCamera();
|
||||||
|
}
|
||||||
|
controller.resumeCamera();
|
||||||
late StreamSubscription sub;
|
late StreamSubscription sub;
|
||||||
sub = controller.scannedDataStream.listen((scanData) {
|
sub = controller.scannedDataStream.listen((scanData) {
|
||||||
sub.cancel();
|
sub.cancel();
|
||||||
|
Loading…
Reference in New Issue
Block a user