Build fixes for wxUSE_WEBVIEW_CHROMIUM && !wxUSE_WEBVIEW_WEBKIT

Fix wxGTK build when CEF backend is available but WebKit(2) one is not.
This commit is contained in:
Vadim Zeitlin 2023-08-31 16:01:21 +02:00
parent 6ee4a4a88c
commit cdab976148
3 changed files with 5 additions and 4 deletions

View file

@ -2280,7 +2280,8 @@
#endif /* wxUSE_TREELISTCTRL */
#if wxUSE_WEBVIEW && !(wxUSE_WEBVIEW_WEBKIT || wxUSE_WEBVIEW_WEBKIT2 || \
wxUSE_WEBVIEW_IE || wxUSE_WEBVIEW_EDGE)
wxUSE_WEBVIEW_IE || wxUSE_WEBVIEW_EDGE || \
wxUSE_WEBVIEW_CHROMIUM)
# ifdef wxABORT_ON_CONFIG_ERROR
# error "wxUSE_WEBVIEW requires at least one backend"
# else

View file

@ -11,7 +11,7 @@
#include "wx/setup.h"
#if wxUSE_WEBVIEW && (wxUSE_WEBVIEW_WEBKIT || wxUSE_WEBVIEW_WEBKIT2) && defined(__WXGTK__)
#if wxUSE_WEBVIEW && defined(__WXGTK__)
class WXDLLIMPEXP_WEBVIEW wxWebViewHistoryItem
{
@ -28,6 +28,6 @@ private:
void* m_histItem;
};
#endif // wxUSE_WEBVIEW && wxUSE_WEBVIEW_WEBKIT && defined(__WXGTK__)
#endif // wxUSE_WEBVIEW && defined(__WXGTK__)
#endif // _WX_GTK_WEBVIEWHISTORYITEM_H_

View file

@ -521,7 +521,7 @@ void wxWebView::InitFactoryMap()
(new wxWebViewFactoryEdge));
#endif
#else
#elif wxUSE_WEBVIEW_WEBKIT || wxUSE_WEBVIEW_WEBKIT2
if(m_factoryMap.find(wxWebViewBackendWebKit) == m_factoryMap.end())
RegisterFactory(wxWebViewBackendWebKit, wxSharedPtr<wxWebViewFactory>
(new wxWebViewFactoryWebKit));