Android 6.0 and up needs permissions asked runtime. https://developer.android.com/training/permissions/requesting.html#java keskiviikko 7. maaliskuuta 2018 22.02.53 UTC+2 David Junior kirjoitti: > > I'm creating a QR code reader on a website and now I need to use this site > in a Mobile version, so I'm creating a WebView that is opening the site. > But when I get to want to use the QR Code is returning me error when giving > permission to use the Android camera. In any browser the QR Code reader > works, on the desktop or on the mobile phone. But when I use the webview, > it does not allow the camera. I need a solution for that. I've inserted all > the permissions and checks I found on the internet but nothing works on any > version of Android (I'm using 6.0) > > <uses-permission android:name="android.permission.CAMERA" /> > <uses-feature android:name="android.hardware.camera" /> > <uses-feature android:name="android.hardware.camera.autofocus" /> > <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" > /> > > > I saw an option to insert a JavaScript to call the camera in WebView but I > could not find how it can be done. Can someone help me > > Thank you in advance. >
-- You received this message because you are subscribed to the Google Groups "Android Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/android-developers. To view this discussion on the web visit https://groups.google.com/d/msgid/android-developers/bd9955c6-5c57-4405-83ee-a97c4f1d74a9%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.

