hlwhl / webview_cef

WebView for Flutter Desktop Apps using CEF(Chromium Embedded Framework) [Work in Progress]
Apache License 2.0
189 stars 54 forks source link

Check failed: !g_instance error on access again to page #117

Closed MobileD3v3l closed 1 month ago

MobileD3v3l commented 7 months ago

Hello,

Following the example proposed in the plugin, if I navigate to that page from a home page it is displayed correctly.

However, when you navigate back to the source page and access in again, the application closes and displays the following message on the terminal:

[0419/092055.443214:FATAL:webview_handler.cc(36)] Verification failed: !g_instance.

What could be the problem?

I have consulted some of the previous issues related to !g_instance, but I have not been able to find the solution.

Greetings

SinyimZhi commented 7 months ago

Same question as #96

SinyimZhi commented 6 months ago

Hi, every one. I've merged multi instance and multi window support branch to main. There is a lot of problems might have been resloved. Could you guys help us to verify what we did success and what new problem brought in? @MobileD3v3l

MobileD3v3l commented 6 months ago

After some tests it seems working correctly. Only one thing, but I need to investigate it deeper as maybe is something on my implementation, JSchannels seem to be lost the second time the app access the webview.

SinyimZhi commented 6 months ago

After some tests it seems working correctly. Only one thing, but I need to investigate it deeper as maybe is something on my implementation, JSchannels seem to be lost the second time the app access the webview.

Jschannel needs to be injected every time a page is loaded, and it‘s lifecycle is affected by the lifecycle of the page.