mirror of
https://github.com/krille-chan/fluffychat
synced 2024-09-10 11:05:10 +00:00
chore: Follow up fix qr code scanner
This commit is contained in:
parent
08930516a5
commit
c7e2dd4f11
1 changed files with 6 additions and 0 deletions
|
@ -59,6 +59,12 @@ class _QrScannerModalState extends State<QrScannerModal> {
|
|||
|
||||
void _onQRViewCreated(QRViewController 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;
|
||||
sub = controller.scannedDataStream.listen((scanData) {
|
||||
sub.cancel();
|
||||
|
|
Loading…
Reference in a new issue