Helper class to simplify creating custom CefClient subclasses.
Please note that the application including this header must set up the compiler options to include the CEF directory as one of the include paths, as this header – unlike wx/webview_chromium.h – includes CEF headers.
Here is a simple example of using this class to customize processing the messages received from the other CEF processes:
{
using wxDelegatingCefClient::wxDelegatingCefClient;
static CefClient* Create(CefClient* client, void* WXUNUSED(data)
{
return new CustomClient(client);
}
bool OnProcessMessageReceived(CefRefPtr<CefBrowser> browser,
CefRefPtr<CefFrame> frame,
CefProcessId source_process,
CefRefPtr<CefProcessMessage> message) override
{
return true;
}
};
void MyFunction()
{
auto configChrome =
if ( !webview->Create(
this,
wxID_ANY, url) )
{
}
}
Helper class to simplify creating custom CefClient subclasses.
Definition: webview_chromium_impl.h:63
wxWebViewChromium is a Chromium-based backend for wxWebView using the Chromium Embedded Framework (CE...
Definition: webview_chromium.h:280
Chromium-specific configuration parameters.
Definition: webview_chromium.h:365
CefClient *(* m_clientCreate)(CefClient *client, void *data)
Function to create the custom CefClient to use if non-null.
Definition: webview_chromium.h:416
This class allows access to web view configuration options and settings, that have to be specified be...
Definition: webview.h:297
virtual void * GetNativeConfiguration() const
Returns the pointer to the native configuration used during creation of a wxWebView.
static wxWebViewConfiguration NewConfiguration(const wxString &backend=wxWebViewBackendDefault)
Create a new wxWebViewConfiguration object.
@ wxID_ANY
Any id: means that we don't care about the id, whether when installing an event handler or when creat...
Definition: defs.h:591
- Since
- 3.3.0