diff --git a/src/Gui/GuiApplicationNativeEventAware.cpp b/src/Gui/GuiApplicationNativeEventAware.cpp index 87ecee72a2..491da710eb 100644 --- a/src/Gui/GuiApplicationNativeEventAware.cpp +++ b/src/Gui/GuiApplicationNativeEventAware.cpp @@ -25,7 +25,26 @@ #include #if defined(Q_OS_LINUX) && defined(SPNAV_FOUND) #include - #include + #include + + #if QT_VERSION >= 0x050000 + #include + #undef Bool + #undef CursorShape + #undef Expose + #undef KeyPress + #undef KeyRelease + #undef FocusIn + #undef FocusOut + #undef FontChange + #undef None + #undef Status + #undef Unsorted + #undef False + #undef True + #undef Complex + #endif // #if QT_VERSION >= 0x050000 + #endif // if defined(Q_OS_LINUX) && defined(SPNAV_FOUND) #include #include @@ -35,10 +54,6 @@ #include "SpaceballEvent.h" #include "Application.h" -#if defined(Q_OS_LINUX) && defined(SPNAV_FOUND) - #include -#endif // if defined(Q_OS_LINUX) && defined(SPNAV_FOUND) - #ifdef _USE_3DCONNEXION_SDK //windows #ifdef Q_OS_WIN diff --git a/src/Gui/GuiApplicationNativeEventAware.h b/src/Gui/GuiApplicationNativeEventAware.h index 8c7def7059..3d5f845e30 100644 --- a/src/Gui/GuiApplicationNativeEventAware.h +++ b/src/Gui/GuiApplicationNativeEventAware.h @@ -32,22 +32,8 @@ class QMainWindow; -#if defined(Q_OS_LINUX) - #include - #undef Bool - #undef CursorShape - #undef Expose - #undef KeyPress - #undef KeyRelease - #undef FocusIn - #undef FocusOut - #undef FontChange - #undef None - #undef Status - #undef Unsorted - #undef False - #undef True - #undef Complex +#if defined(Q_OS_LINUX) && QT_VERSION >= 0x050000 + #include #include #elif defined(Q_OS_WIN) && defined(_USE_3DCONNEXION_SDK)