Page 1 of 1

OnClose of Window not calling the required method

PostPosted: Wed Oct 13, 2021 8:49 am
by syed
Hi

We have upgraded the CEF version from 57.0.0.0 to 84.4.10.0

and with this the registering for ObjectFor scripting was changed from
ChromiumWebBrowser.RegisterJsObject("foo", ObjectForScripting, new BindingOptions { CamelCaseJavascriptNames = false });

to

ChromiumWebBrowser.JavascriptObjectRepository.Register("foo", ObjectForScripting, isAsync: false, options: new BindingOptions { CamelCaseJavascriptNames = false });

Now OnClose of Window
on onbeforeunload we used to call foo.method1()
with previous version foo.metho1() used to get called.

with new version i see that onbeforeunload event is raised and the line of code which invokes the foo.method1() is also executed but the call is not reaching the foo.method1().

How should I get the desired behavior in new version.

Re: OnClose of Window not calling the required method

PostPosted: Wed Oct 13, 2021 2:08 pm
by amaitland
Does the problem reproduce with version 94?

Re: OnClose of Window not calling the required method

PostPosted: Mon Oct 18, 2021 4:03 am
by syed
What are the version which are supported for CEFSharp ?

Re: OnClose of Window not calling the required method

PostPosted: Mon Oct 18, 2021 3:47 pm
by amaitland
https://github.com/cefsharp/CefSharp/releases

The latest release is supported.