build: fix for wx using GTK2
Use the __WXGTK3__ macro to check for GTK3 when setting the gdk backend to X11 when Wayland EGL is not available, GTK2 does not have this function and always uses X11 anyway. Signed-off-by: Rafael Kitover <rkitover@gmail.com>
This commit is contained in:
parent
834c7de86c
commit
d516683a77
|
@ -4,7 +4,7 @@
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef __WXGTK__
|
#ifdef __WXGTK3__
|
||||||
#include <gdk/gdk.h>
|
#include <gdk/gdk.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -135,7 +135,7 @@ int main(int argc, char** argv) {
|
||||||
#endif // DEBUG
|
#endif // DEBUG
|
||||||
|
|
||||||
// Launch under xwayland on Wayland if EGL is not available.
|
// Launch under xwayland on Wayland if EGL is not available.
|
||||||
#if defined(__WXGTK__) && !defined(HAVE_WAYLAND_EGL)
|
#if defined(__WXGTK3__) && !defined(HAVE_WAYLAND_EGL)
|
||||||
wxString xdg_session_type = wxGetenv("XDG_SESSION_TYPE");
|
wxString xdg_session_type = wxGetenv("XDG_SESSION_TYPE");
|
||||||
wxString wayland_display = wxGetenv("WAYLAND_DISPLAY");
|
wxString wayland_display = wxGetenv("WAYLAND_DISPLAY");
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue