Finally figured it out. Well... kind of.
The solution is to not use the Webview, but instead WebEngineView, and make sure to include the onFeaturePermissionRequested method.
In conclusion, just steal the code from the discord app.
Best posts made by ari
Latest posts made by ari
Weird Issue with c++ vs qml Webview
Ok, I know its likely that this is a bug, that no one here can help with, but I'm not sure where I would submit the bug report, so any hints on that will also be appreciated.
The camera doesnt work on C++ projects but does with qml only (with the WebEngineView).
Steps to replicate:
- Create 'qml only' and 'c++' clickable projects.
- Change apparmor permissions for both
- Add WebEngineView to Main.qml of both
- Point url to site with camera access
- Discover that: qml project works with camera, c++ doesn't.
(error seems to show as: "NotReadableError: could not start video source")
Is this a WebEngineView bug, c++ bug, clickable... Is it a feature!?
Any help would be greatly appreciated.
Camera not working in Webview
Using a webview in QML, testing with sites like: https://webcamtests.com/ the camera does not appear.
Trying the same site on the regular morph browser works as expected.
I've already set "camera" as one of the policy_groups.
What am I missing?