X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/17a1ebd101f0653e69736416a2a28d0ada423141..eaba6eba3a1ca393e6ecbafa601cc3b54e705901:/src/unix/utilsx11.cpp?ds=inline diff --git a/src/unix/utilsx11.cpp b/src/unix/utilsx11.cpp index c31f11ee97..b81271298d 100644 --- a/src/unix/utilsx11.cpp +++ b/src/unix/utilsx11.cpp @@ -15,10 +15,15 @@ #include "wx/wxprec.h" #include "wx/unix/utilsx11.h" + +#ifndef WX_PRECOMP + #include "wx/log.h" + #include "wx/app.h" + #include "wx/icon.h" +#endif + #include "wx/iconbndl.h" #include "wx/image.h" -#include "wx/icon.h" -#include "wx/log.h" #ifdef __VMS #pragma message disable nosimpint @@ -297,7 +302,7 @@ static bool wxQueryWMspecSupport(Display *display, Window rootWnd, Atom feature) False, XA_WINDOW, &type, &format, &nwins, &after, (unsigned char **)&wins); if ( type != XA_WINDOW || nwins <= 0 || wins[0] == None ) - return FALSE; + return false; XFree(wins); // Query for supported features: @@ -306,7 +311,7 @@ static bool wxQueryWMspecSupport(Display *display, Window rootWnd, Atom feature) False, XA_ATOM, &type, &format, &natoms, &after, (unsigned char **)&atoms); if ( type != XA_ATOM || atoms == NULL ) - return FALSE; + return false; // Lookup the feature we want: for (unsigned i = 0; i < natoms; i++) @@ -314,11 +319,11 @@ static bool wxQueryWMspecSupport(Display *display, Window rootWnd, Atom feature) if ( atoms[i] == feature ) { XFree(atoms); - return TRUE; + return true; } } XFree(atoms); - return FALSE; + return false; } #endif @@ -381,7 +386,7 @@ static bool wxKwinRunning(Display *display, Window rootWnd) &type, &format, &nitems, &after, (unsigned char**)&data) != Success) { - return FALSE; + return false; } bool retval = (type == KWIN_RUNNING && @@ -427,7 +432,7 @@ static void wxSetKDEFullscreen(Display *display, Window rootWnd, } XChangeProperty(display, w, _NET_WM_WINDOW_TYPE, XA_ATOM, 32, - PropModeReplace, (unsigned char *) &data, lng); + PropModeReplace, (unsigned char *) &data[0], lng); XSync(display, False); if (wasMapped) @@ -575,9 +580,9 @@ int wxCharCodeXToWX(KeySym keySym) case XK_Down: id = WXK_DOWN; break; case XK_Next: - id = WXK_NEXT; break; + id = WXK_PAGEDOWN; break; case XK_Prior: - id = WXK_PRIOR; break; + id = WXK_PAGEUP; break; case XK_Menu: id = WXK_MENU; break; case XK_Select: @@ -704,8 +709,8 @@ KeySym wxCharCodeWXToX(int id) case WXK_PAUSE: keySym = XK_Pause; break; case WXK_ESCAPE: keySym = XK_Escape; break; case WXK_SPACE: keySym = ' '; break; - case WXK_PRIOR: keySym = XK_Prior; break; - case WXK_NEXT : keySym = XK_Next; break; + case WXK_PAGEUP: keySym = XK_Prior; break; + case WXK_PAGEDOWN: keySym = XK_Next; break; case WXK_END: keySym = XK_End; break; case WXK_HOME : keySym = XK_Home; break; case WXK_LEFT : keySym = XK_Left; break; @@ -770,8 +775,6 @@ KeySym wxCharCodeWXToX(int id) // check current state of a key // ---------------------------------------------------------------------------- -#include - bool wxGetKeyState(wxKeyCode key) { wxASSERT_MSG(key != WXK_LBUTTON && key != WXK_RBUTTON && key != @@ -812,8 +815,3 @@ bool wxGetKeyState(wxKeyCode key) } #endif // __WXX11__ || __WXGTK__ || __WXMOTIF__ - - - - -