diff options
Diffstat (limited to 'components')
| -rw-r--r-- | components/QRCodeScanner.qml | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/components/QRCodeScanner.qml b/components/QRCodeScanner.qml index 10c1592a..d9a6d933 100644 --- a/components/QRCodeScanner.qml +++ b/components/QRCodeScanner.qml @@ -131,4 +131,11 @@ Rectangle { root.state = "Stopped" } } + + Component.onCompleted: { + if( QtMultimedia.availableCameras.length == 0) { + console.log("No camera available. Disable qrScannerEnabled"); + appWindow.qrScannerEnabled = false; + } + } } |
