-
Notifications
You must be signed in to change notification settings - Fork 50
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
webview - crash when viewing local server content? #8
Comments
Hmm - we just had a go at recreating this and couldn't get it to fail. a) Does the unmodified choc test app also crash? |
Not, it works fine.
No, all good there:
I'm trying various other js libraries and they seem to work fine. It's very odd.. |
* quick workaround to resolve #8 * for some reason the enviornment completed handler is being called multiple times, far later than actual creation, needs more investigation, but this prevents crashing
* our ICoreWebView2 declaration for `add_PermissionRequested` didn't have the actual type as the first param (we've used void* in many places to avoid copying other bits of the webview header we don't need), and as we actually call that method with an `EventHandler` instance, the wrong method ended up being called when a page requests a permission (the first virtual method gets called instead, e.g the enviornment created handler) - we could instead just remove the permissions handler, as its clearly never been called before, but we might end up putting more logic there, so will keep it setup for now * this is the actual fix for #8
Pretty sure we've fixed this, so going to close the issue - thanks for reporting, and let us know if you spot any other oddities! |
Nice one. 👍 |
I'm trying to display some content running on a local server (via python http>server, or VSCode's liver-server extensions). The html couldn't be simpler:
It runs fine in all of the browsers I've installed, but it causes an exception with choc_WebView.h here:
I'm just using the demo code with
navigate()
instead ofsetHTML()
Any ideas? I'm well out of my depth here. Am I correct in assuming that if it runs in Edge it should run fine?[edit] It seems that it might be something unique to p5js that causes this problem. If I try with another js library, it works fine. I'd still love to know if it could be resolved...
The text was updated successfully, but these errors were encountered: