PermissionRequested event not firing
Opened this issue · 2 comments
First of all, thanks for this repo. Trying to get a camera feed working has been tough!
I attempted to incorporate your code into my project. I am able to debug and confirm that the following line is running in my MainPage.xaml.Windows.cs
. However, the handler never gets invoked and the web debug console reports a permission denied error.
e.WebView.CoreWebView2.PermissionRequested += permissionHandler.OnPermissionRequested;
If I query or the state of my permission, I get "denied."
navigator.permissions.query({name: "camera"});
Do you think I could be in the "stuck" state you mentioned from my fumbling around before finding your solution? If so, do you have any idea how to clear this denial decision in my debug browser?
Thanks!
Hey, I actually found a solution. It may not be perfect, but I got around this by changing the Package name
in the .appxmanifest
file, running the app, and then changing it back. This cleared the state of permissions held by the WebView/app.