From 95805ea38724c180e245adf08138daf4b912d8e8 Mon Sep 17 00:00:00 2001 From: xawotihs Date: Sun, 15 Dec 2013 00:26:04 +0100 Subject: [PATCH] Fixed QT mingw cross compile with QT4.8 --- JGE/include/qt/corewrapper.h | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/JGE/include/qt/corewrapper.h b/JGE/include/qt/corewrapper.h index 3ea2fa686..cd019c6a7 100644 --- a/JGE/include/qt/corewrapper.h +++ b/JGE/include/qt/corewrapper.h @@ -136,8 +136,20 @@ signals: private slots: private: - int lastPosx(){ return m_lastPos.x()*devicePixelRatio();} - int lastPosy(){ return m_lastPos.y()*devicePixelRatio();} + int lastPosx(){ +#if QT_VERSION >= 0x050000 + return m_lastPos.x()*devicePixelRatio(); +#else + return m_lastPos.x(); +#endif + } + int lastPosy(){ +#if QT_VERSION >= 0x050000 + return m_lastPos.y()*devicePixelRatio(); +#else + return m_lastPos.y(); +#endif + } void timerEvent( QTimerEvent* ); void doAndEnqueue(JButton action) { m_engine->HoldKey_NoRepeat(action);