Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Barcode Scanning Overlay fails to open on Android 11 #29

Closed
tenglandct opened this issue Dec 23, 2020 · 4 comments
Closed

Barcode Scanning Overlay fails to open on Android 11 #29

tenglandct opened this issue Dec 23, 2020 · 4 comments

Comments

@tenglandct
Copy link

Hi,

This plugin does not appear to work on Android 11.

Calling the startScanning method launches the scanner activity but the user is just left with a black screen. The user is able to quit back to the app by using the back button and continue using the app without any issue but the scanning functionality simply does not function.

This has been reported by a customer using Samsung S20 and also I have replicated using Browserstack and Android 11 devices available there.

Initially I noticed logcat info around missing the SYSTEM_ALERT_WINDOW permission (which is a change in Android 11), but having manually added a uses-permission for this to the Android Manifest through the config.xml, the behaviour is the same but there no longer a warning (i.e. I believe the permission has been applied correctly but has not had the desired result)

Regards

@LazarIlievski
Copy link

HI @tenglandct
Thank you for contacting the Customer Service Department.
Most probably starting from android 11, orientation as configChages is not working and instead of that, we need to use screenSize|screenLayout.

This is a recommendation from an android a long time ago, but up until android 11, it was still working.

However in your application open AndroidManifest.xml and make this change to ScannerActivity
support_Screenshot_110

Regards,

@LazarIlievski
Copy link

LazarIlievski commented Jan 28, 2021

We just released a new version phonegap-manateeworks-v3 3.1.4 and the issue is resolved. Please make a test with the new release and if everything is fine please close the issue.

Regards,

@tenglandct
Copy link
Author

Great! Thanks Lazar, I will test now

@tenglandct
Copy link
Author

Hi guys, confirmed working on some test devices that we have - many thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants