X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/655719367ac5e131d9642e5783f3ecf64d1a3385..7e4fb3b8168f4f2dbf2f8a246d3e094a8ccba194:/src/unix/utilsx11.cpp diff --git a/src/unix/utilsx11.cpp b/src/unix/utilsx11.cpp index a5e49b8870..8d400126c6 100644 --- a/src/unix/utilsx11.cpp +++ b/src/unix/utilsx11.cpp @@ -29,7 +29,7 @@ #pragma message enable nosimpint #endif -#ifdef __WXGTK20__ +#ifdef __WXGTK__ #include #include #endif @@ -765,9 +765,11 @@ KeySym wxCharCodeWXToX(int id) bool wxGetKeyState(wxKeyCode key) { #if defined(__WXX11__) - Display *pDisplay = wxApp::GetDisplay(); + Display *pDisplay = (Display*) wxApp::GetDisplay(); #elif defined(__WXGTK__) Display *pDisplay = GDK_DISPLAY(); +#elif defined(__WXMOTIF__) + Display *pDisplay = (Display*) (wxTheApp ? wxTheApp->GetInitialDisplay() : NULL); #else #error Add code to get the DISPLAY for this platform #endif