Tobias Taschner
80c04e3941
Merge branch 'master' into webview_script_message
2021-03-01 09:57:13 +01:00
Maarten Bent
7532532800
Mention GCC/Clang support in wxWebViewEdge documentation
...
And add a comment explaining the name of the EventRegistrationToken include guard.
2021-03-01 00:09:23 +01:00
Tobias Taschner
5a30bbe38f
Apply suggestions from code review
...
Co-authored-by: PB <PBforDev@gmail.com >
2021-02-28 22:33:15 +01:00
Tobias Taschner
f419240335
Add Apple transport security to wxWebView docs
2021-02-28 20:44:38 +01:00
Tobias Taschner
ca5133fff7
Add usage documentation to wxWebView::AddScriptMessageHandler()
2021-02-28 20:41:49 +01:00
Tobias Taschner
575ae90d85
Fix trailing whitespace
2021-02-28 20:03:36 +01:00
Tobias Taschner
6f7ac6a934
Add wxWebView::AddUserScript()
...
This allows to inject javascript code across multiple pages
2021-02-26 23:41:39 +01:00
Tobias Taschner
f2bfa7d446
Initial AddScriptMessageHandler() documentation
2021-02-26 22:35:49 +01:00
Tobias Taschner
b1d558a612
Disabled dev tools per default for Edge
...
This unifies the behavior among backends and is probably
the more useful default for most applications.
2021-02-26 21:55:10 +01:00
Tobias Taschner
3af4702b11
Implement wxWebView::EnableAccessToDevTools() for GTK
2021-02-26 18:53:46 +01:00
Tobias Taschner
c3d0d7d000
Identify script handler in message event
2021-02-26 16:59:56 +01:00
Tobias Taschner
011035ef08
Add wxEVT_WEBVIEW_SCRIPT_MESSAGE_RECEIVED event
2021-02-26 15:41:41 +01:00
Tobias Taschner
e09063186c
Provide generic wxWebView::Find() implementation
...
This implementation is based on javascript 'window.find()'
https://developer.mozilla.org/en-US/docs/Web/API/Window/find
It's not standard, but implemented in most browsers.
It's not a complete implementation as it can't determine how
many search results can be found.
If the backends API provides a native find interface it should be
used instead of this implementation, but it's good fallback.
2021-02-10 23:55:18 +01:00
Tobias Taschner
5512089d5b
Apply suggestions from code review
...
Co-authored-by: VZ <vz-github@zeitlins.org >
2021-02-09 23:35:01 +01:00
Tobias Taschner
a3f85e9cd5
Implement wxEVT_WEBVIEW_FULLSCREEN_CHANGED in GTK
2021-02-09 22:28:29 +01:00
Tobias Taschner
f6a23a0431
Add wxEVT_WEBVIEW_FULLSCREEN_CHANGED event
...
The event is triggered by wxWebView when the page requests fullscreen view.
It's currently only implemented for the edge backend.
2021-02-09 22:28:29 +01:00
Tobias Taschner
1ee05c54ed
CMake: Download SDK when wxUSE_WEBVIEW_EDGE=ON
...
Automatically download the WebView2 SDK from nuget (official repo for the SDK)
when enabling wxUSE_WEBVIEW_EDGE to simplify usage.
Copying to 3rdparty/webview2 is still supported optionally.
2021-02-08 21:29:08 +01:00
Tobias Taschner
d17e8978a6
Make wxWebView::RunScript() const
2021-02-05 22:18:31 +01:00
Tobias Taschner
788bef2cf2
Select Edge as the default backend on MSW
...
If enabled and available at runtime use the Edge backend.
This is probably more useful for most users.
2021-02-05 22:18:29 +01:00
Tobias Taschner
b351e7762d
Move common wxWebView code to base class
...
Removes duplicate code in the various webview backends
2021-02-05 22:18:29 +01:00
Tobias Taschner
0d82348328
Add wxWebView::GetBackendVersionInfo()
...
Allows to get the WebView backend version if available
Currently implemented for IE, Edge and webkit2.
2021-02-05 22:18:28 +01:00
Tobias Taschner
489afb3336
Allow using a fixed version with wxWebViewEdge
...
A fixed version may be distributed with the application
and wxWebViewEdge::MSWSetBrowserExecutableDir() allows
it's usage with wxWebViewEdge.
2021-02-05 22:18:28 +01:00
Tobias Taschner
10398b8f72
macOS: Document missing wxWebView features and don't test for them
2020-12-14 13:40:32 +01:00
Tobias Taschner
4df334cec4
macOS/iOS: Use WKWebView for wxWebView Implementation
...
WKWebView replaces
WebView on macOS (available since 10.10, deprecated since 10.14) and
UIWebView on iOS (available since 8.0 deprecated since 10.0).
Using WKWebView ensures future compatiblity and unifies the interface
used for iOS and macOS.
2020-12-14 10:18:01 +01:00
Tobias Taschner
46d123b953
WebViewEdge: Allow edge webview2 installation during runtime
...
Check if edge webview runtime is available in the call to
wxWebView::IsBackendAvailable() instead of only doing it during
process initialization. This allows an application to install
the Edge WebView2 Runtime during runtime and use the edge webview
afterwards without restarting the process.
2020-11-06 09:19:17 +01:00
Tobias Taschner
038782a684
Update WebView Edge min required version to 1.0.622.22
...
While technically it still builds with older versions,
version 1.0.622.22 ist the first non preview release which should
make the included webview loader DLL the most compatible for the
forseable future.
2020-10-20 15:12:09 +02:00
Maarten Bent
300fe1a6f9
Add option to wxWebViewHandler to set a custom security URL
...
This will be used by wxWebViewIE to modify the security URL and domain when
parsing a URL.
2020-07-28 21:22:21 +02:00
Tobias Taschner
1666f58bc6
Change documentation references from OS X to macOS ( #1927 )
...
Since OS X 10.12 it has been named macOS so it makes sense
to reference it in documentation as such, even when it
sometimes refers to older versions which were called (Mac) OS X.
2020-07-04 22:08:24 +02:00
Vadim Zeitlin
d7f19ee610
Fix spelling in comments and documentation using codespell
...
Apply the utility from https://github.com/codespell-project/codespell/
to fix spelling issues in the headers under both include and interface
directories and add a file with a couple of exceptions.
The exact command line used was:
$ codespell -w -I misc/scripts/codespell.ignore -i 3 in*
2020-06-27 22:56:22 +02:00
Hertatijanto Hartono
895424ecc0
Add wxWebView::SetZoomFactor(float) and GetZoomFactor()
...
The new method allows to set the zoom level more precisely than the
existing SetZoom(wxWebViewZoom).
Also improve the webview sample by using radio menu items instead of
check items and manually resetting them.
Closes https://github.com/wxWidgets/wxWidgets/pull/1894
Closes #18769 .
2020-06-18 03:13:00 +02:00
Tobias Taschner
7d1c40ecf5
Updated wxWebViewEdge for SDK to 0.9.488
...
Requires Edge 84.0.488.0 or newer
Another SDK release before 1.0 includes some
breaking changes regarding naming
2020-04-20 23:00:10 +02:00
Tobias Taschner
613687ecb5
Updated wxWebViewEdge for SDK 0.9.430
...
This first beta release of the WebView2 SDK has many identifiers
renamed and webview interfaces split to Host and WebView.
Closes https://github.com/wxWidgets/wxWidgets/pull/1743
2020-02-29 15:40:45 +01:00
Vadim Zeitlin
0b2dd516c1
Slightly improve Edge webview backend setup instructions
...
Make it even more clear where should the files go and which files should
be copied, to avoid any ambiguity.
2020-01-22 03:36:38 +01:00
Tobias Taschner
fb0e82e9d1
Implement GetPageSource() and GetPageText()
2020-01-17 21:09:51 +01:00
Tobias Taschner
bb508dc347
Implement text selection in wxWebViewEdge
...
Text selection/copy/paste etc implemented via javascript
2020-01-16 20:50:26 +01:00
Tobias Taschner
d829e5e832
Document unsupported parameters
2020-01-16 10:37:31 +01:00
Tobias Taschner
9f11abd8fc
Rename wxWebView::EnableDevTools() to EnableAccessToDevTools()
2020-01-16 09:38:35 +01:00
Tobias Taschner
b4764bbf4f
Fix typo in interface/wx/webview.h
...
Co-Authored-By: PB <PBforDev@gmail.com >
2020-01-15 22:14:23 +01:00
Tobias Taschner
903279a9af
Add a note about WebView2 SDK license requirements
2020-01-15 17:05:34 +01:00
Tobias Taschner
bce0e65a80
Rename wxWebView::IsDevToolsEnabled() to IsAccessToDevToolsEnabled()
2020-01-15 16:22:43 +01:00
Tobias Taschner
c3f0b7a6cb
Apply suggestions from code review
...
Co-Authored-By: VZ <vz-github@zeitlins.org >
2020-01-15 15:55:49 +01:00
Tobias Taschner
049d253a85
Fix typo and wording in webview documentation
2020-01-14 09:55:30 +01:00
Tobias Taschner
19b85d6370
Update interface/wx/webview.h
...
Co-Authored-By: PB <PBforDev@gmail.com >
2020-01-12 21:10:41 +01:00
Tobias Taschner
68c46681a0
Document wxWebViewEdge build process
2020-01-11 15:43:22 +01:00
Tobias Taschner
d72e5874eb
Add wxWebView methods to enable dev tools
...
Currently only implemented for the Edge (Chromium) backend.
2020-01-10 22:27:36 +01:00
Markus Pingel
6a99e7e273
Add wxWebView Edge (Chromium) implementation
...
This backend requires WebView2 SDK and enables usage of Edge (Chromium)
on Windows 7 and newer
2020-01-10 22:22:28 +01:00
Tobias Taschner
095a93e0c0
Add wxWebView::IsBackendAvailable()
...
This allows to check if a specified backend has been registered before creation of a new instance
2020-01-09 13:44:06 +01:00
Maarten Bent
9455fe2d21
Move wxWebViewIE specific functions to correct interface class
2019-11-14 00:04:48 +01:00
Robin Dunn
8b489f53d6
MSWSetEmulationLevel and MSWSetModernEmulationLevel are static
2019-06-10 21:03:40 -07:00
Vadim Zeitlin
8fbca5cb70
Remove all trailing spaces
...
No real changes, just clean up sources by removing trailing spaces from
all the non-generated files.
This should hopefully avoid future commits mixing significant changes
with insignificant whitespace ones.
2019-01-30 17:35:54 +01:00