-
Notifications
You must be signed in to change notification settings - Fork 42
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
应用闪退 #96
Comments
是macos下的 |
因为现在这个插件还不支持多实例,你在使用overlay的时候第一次关闭的时候是销毁了webviewhandler,但是Webviewhandler本身是单例的。所以这里判空会报错,如果你想支持多实例使用的话,目前这个插件还有一段路要走,我个人的fork上有个试验性的分支,但是依然面临着很多问题,尤其是面对多窗口时。 |
尤其是mac上面问题更多,实在是之前没有macos的技术栈,一直做的很慢 /笑哭 |
Hey, @SinyimZhi, I also faced that "!g_instance" problem and probably found the solution to solve it. In our case it's not about WebView multi instance, but about same instance reinitialization. We have separate screen deep inside our application which contains WebView, the business logic is to open/close it time to time. Also it seems similar problem was already mentioned in prevoius issue which was closed as not reproducible. I think I figured out the solution. Please chech the I am on the recent (i.e. Jan 15 2024) commit and changed few things. This part of handler & app initialization:
Was changed by me to this one:
And this part of CEF initialization:
To this one:
Now everything seems working fine and I do not face any issue. Hope this stuff can be helpful to be implemented in update and/or will be useful for further understanding. |
@alldev In fact, the |
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? @alldev @Crush-star @ |
我用overlay展示了这个webview,第一个打开没问题,关闭后第二次打开应用闪退
调试模式下报错为断开设备连接,代码会debug到
WebviewHandler::WebviewHandler() {
DCHECK(!g_instance);
g_instance = this;
}
FATAL:webview_handler.cc(35)] Check failed: !g_instance.
帮看看,我的老哥
The text was updated successfully, but these errors were encountered: