Miscellaneous fixes for WebKit2 wxWebView backend
See #23497. (cherry picked from commit 8d8f94da641fc95a6d5203276fa2e26abb42e9fc)
This commit is contained in:
parent
a34e5505ef
commit
171369203f
@ -255,6 +255,7 @@ wxGTK:
|
||||
|
||||
- Dramatically optimize adding many items to wxChoice (Ian McInerney, #23443).
|
||||
- Improve document wxGLCanvas::CreateSurface() (Dan Gudmundsson, #23366).
|
||||
- Fix loading WebKit2 extension when using wxWebView (Scott Talbert, #23497).
|
||||
|
||||
wxMSW:
|
||||
|
||||
|
@ -533,7 +533,7 @@ wxgtk_initialize_web_extensions(WebKitWebContext *context,
|
||||
|
||||
for ( size_t n = 0; n < WXSIZEOF(directories); ++n )
|
||||
{
|
||||
if ( !TrySetWebExtensionsDirectory(context, directories[n]) )
|
||||
if ( TrySetWebExtensionsDirectory(context, directories[n]) )
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -232,9 +232,11 @@ TEST_CASE_METHOD(WebViewTestCase, "WebView", "[wxWebView]")
|
||||
// With WebKit SelectAll() sends a request to perform the selection to
|
||||
// another process via proxy and there doesn't seem to be any way to
|
||||
// wait until this request is actually handled, so loop here for some a
|
||||
// bit before giving up.
|
||||
for ( wxStopWatch sw; !m_browser->HasSelection() && sw.Time() < 50; )
|
||||
wxMilliSleep(1);
|
||||
// bit before giving up. Avoid calling HasSelection() right away
|
||||
// without wxYielding a bit because this seems to cause the extension
|
||||
// to hang with webkit 2.40.0+.
|
||||
for ( wxStopWatch sw; sw.Time() < 50; )
|
||||
wxYield();
|
||||
#endif // wxUSE_WEBVIEW_WEBKIT2
|
||||
|
||||
CHECK(m_browser->HasSelection());
|
||||
|
Loading…
Reference in New Issue
Block a user