Make QtCore compile with on Windows when -qpa is used
Core functionality almost never is window system dependent. Reviewed-by: Friedemann Kleint
This commit is contained in:
parent
6a3dce1995
commit
f86334a015
@ -856,7 +856,9 @@ namespace QT_NAMESPACE {}
|
||||
WIN16 - unsupported
|
||||
*/
|
||||
|
||||
#if defined(Q_OS_MSDOS)
|
||||
#if defined (Q_WS_QPA)
|
||||
|
||||
#elif defined(Q_OS_MSDOS)
|
||||
# define Q_WS_WIN16
|
||||
# error "Qt requires Win32 and does not work with Windows 3.x"
|
||||
#elif defined(_WIN32_X11_)
|
||||
@ -1139,7 +1141,7 @@ redefine to built-in booleans to make autotests work properly */
|
||||
|
||||
//defines the type for the WNDPROC on windows
|
||||
//the alignment needs to be forced for sse2 to not crash with mingw
|
||||
#if defined(Q_WS_WIN)
|
||||
#if defined(Q_OS_WIN)
|
||||
# if defined(Q_CC_MINGW)
|
||||
# define QT_ENSURE_STACK_ALIGNED_FOR_SSE __attribute__ ((force_align_arg_pointer))
|
||||
# else
|
||||
@ -1560,7 +1562,7 @@ public:
|
||||
#else
|
||||
# error "Qt not configured correctly, please run configure"
|
||||
#endif
|
||||
#if defined(Q_WS_WIN) || defined(Q_OS_CYGWIN)
|
||||
#if defined(Q_OS_WIN) || defined(Q_OS_CYGWIN)
|
||||
enum WinVersion {
|
||||
WV_32s = 0x0001,
|
||||
WV_95 = 0x0002,
|
||||
@ -1669,7 +1671,7 @@ inline QT3_SUPPORT bool qSysInfo(int *wordSize, bool *bigEndian)
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(Q_WS_WIN) || defined(Q_OS_CYGWIN)
|
||||
#if defined(Q_OS_WIN) || defined(Q_OS_CYGWIN)
|
||||
#if defined(QT3_SUPPORT)
|
||||
inline QT3_SUPPORT bool qt_winUnicode() { return true; }
|
||||
inline QT3_SUPPORT int qWinVersion() { return QSysInfo::WindowsVersion; }
|
||||
@ -1679,7 +1681,7 @@ inline QT3_SUPPORT int qWinVersion() { return QSysInfo::WindowsVersion; }
|
||||
#define QT_WA(unicode, ansi) unicode
|
||||
#define QT_WA_INLINE(unicode, ansi) (unicode)
|
||||
|
||||
#endif /* Q_WS_WIN */
|
||||
#endif /* Q_OS_WIN */
|
||||
|
||||
#ifndef Q_OUTOFLINE_TEMPLATE
|
||||
# define Q_OUTOFLINE_TEMPLATE
|
||||
|
@ -50,7 +50,7 @@
|
||||
|
||||
#if defined __cplusplus
|
||||
#include <qglobal.h>
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
# define _POSIX_
|
||||
# include <limits.h>
|
||||
# undef _POSIX_
|
||||
|
@ -1746,7 +1746,7 @@ QFileInfoList QDir::drives()
|
||||
*/
|
||||
QChar QDir::separator()
|
||||
{
|
||||
#if defined (Q_FS_FAT) || defined(Q_WS_WIN) || defined(Q_OS_SYMBIAN)
|
||||
#if defined (Q_FS_FAT) || defined(Q_OS_WIN) || defined(Q_OS_SYMBIAN)
|
||||
return QLatin1Char('\\');
|
||||
#elif defined(Q_OS_UNIX)
|
||||
return QLatin1Char('/');
|
||||
|
@ -77,7 +77,7 @@ class Q_AUTOTEST_EXPORT QFSFileEnginePrivate : public QAbstractFileEnginePrivate
|
||||
Q_DECLARE_PUBLIC(QFSFileEngine)
|
||||
|
||||
public:
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
static QString longFileName(const QString &path);
|
||||
#endif
|
||||
|
||||
@ -143,7 +143,7 @@ public:
|
||||
int getMapHandle();
|
||||
#endif
|
||||
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
HANDLE fileHandle;
|
||||
HANDLE mapHandle;
|
||||
QHash<uchar *, DWORD /* offset % AllocationGranularity */> maps;
|
||||
|
@ -93,7 +93,7 @@ QT_END_NAMESPACE
|
||||
#include <qsocketnotifier.h>
|
||||
#include <qtimer.h>
|
||||
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
#include <private/qwineventnotifier_p.h>
|
||||
#endif
|
||||
|
||||
@ -764,10 +764,10 @@ QProcessPrivate::QProcessPrivate()
|
||||
dying = false;
|
||||
emittedReadyRead = false;
|
||||
emittedBytesWritten = false;
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
pipeWriter = 0;
|
||||
processFinishedNotifier = 0;
|
||||
#endif // Q_WS_WIN
|
||||
#endif // Q_OS_WIN
|
||||
#ifdef Q_OS_UNIX
|
||||
serial = 0;
|
||||
#endif
|
||||
|
@ -171,7 +171,7 @@ CApaCommandLine* QCoreApplicationPrivate::symbianCommandLine()
|
||||
|
||||
#endif
|
||||
|
||||
#if defined(Q_WS_WIN) || defined(Q_WS_MAC)
|
||||
#if defined(Q_OS_WIN) || defined(Q_WS_MAC)
|
||||
extern QString qAppFileName();
|
||||
#endif
|
||||
|
||||
@ -1285,7 +1285,7 @@ void QCoreApplication::postEvent(QObject *receiver, QEvent *event, int priority)
|
||||
*/
|
||||
bool QCoreApplication::compressEvent(QEvent *event, QObject *receiver, QPostEventList *postedEvents)
|
||||
{
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
Q_ASSERT(event);
|
||||
Q_ASSERT(receiver);
|
||||
Q_ASSERT(postedEvents);
|
||||
@ -1991,7 +1991,7 @@ QString QCoreApplication::applicationFilePath()
|
||||
if (!d->cachedApplicationFilePath.isNull())
|
||||
return d->cachedApplicationFilePath;
|
||||
|
||||
#if defined(Q_WS_WIN)
|
||||
#if defined(Q_OS_WIN)
|
||||
d->cachedApplicationFilePath = QFileInfo(qAppFileName()).filePath();
|
||||
return d->cachedApplicationFilePath;
|
||||
#elif defined(Q_WS_MAC)
|
||||
|
@ -50,7 +50,7 @@
|
||||
#include <QtCore/qstringlist.h>
|
||||
#endif
|
||||
|
||||
#if defined(Q_WS_WIN) && !defined(tagMSG)
|
||||
#if defined(Q_OS_WIN) && !defined(tagMSG)
|
||||
typedef struct tagMSG MSG;
|
||||
#endif
|
||||
|
||||
@ -168,7 +168,7 @@ public:
|
||||
static QT3_SUPPORT int loopLevel();
|
||||
#endif
|
||||
|
||||
#if defined(Q_WS_WIN)
|
||||
#if defined(Q_OS_WIN)
|
||||
virtual bool winEventFilter(MSG *message, long *result);
|
||||
#endif
|
||||
|
||||
@ -280,7 +280,7 @@ Q_CORE_EXPORT void qAddPostRoutine(QtCleanUpFunction);
|
||||
Q_CORE_EXPORT void qRemovePostRoutine(QtCleanUpFunction);
|
||||
Q_CORE_EXPORT QString qAppName(); // get application name
|
||||
|
||||
#if defined(Q_WS_WIN) && !defined(QT_NO_DEBUG_STREAM)
|
||||
#if defined(Q_OS_WIN) && !defined(QT_NO_DEBUG_STREAM)
|
||||
Q_CORE_EXPORT QString decodeMSG(const MSG &);
|
||||
Q_CORE_EXPORT QDebug operator<<(QDebug, const MSG &);
|
||||
#endif
|
||||
|
@ -240,7 +240,7 @@ void QCoreApplicationPrivate::removePostedTimerEvent(QObject *object, int timerI
|
||||
}
|
||||
}
|
||||
|
||||
#if defined(Q_WS_WIN) && !defined(QT_NO_DEBUG_STREAM)
|
||||
#if defined(Q_OS_WIN) && !defined(QT_NO_DEBUG_STREAM)
|
||||
/*****************************************************************************
|
||||
Convenience functions for convert WM_* messages into human readable strings,
|
||||
including a nifty QDebug operator<< for simpel QDebug() << msg output.
|
||||
|
@ -306,7 +306,7 @@ public:
|
||||
typedef QList<WinTimerInfo*> WinTimerVec; // vector of TimerInfo structs
|
||||
typedef QHash<int, WinTimerInfo*> WinTimerDict; // fast dict of timers
|
||||
|
||||
#if !defined(DWORD_PTR) && !defined(Q_WS_WIN64)
|
||||
#if !defined(DWORD_PTR) && !defined(Q_OS_WIN64)
|
||||
#define DWORD_PTR DWORD
|
||||
#endif
|
||||
|
||||
|
@ -53,7 +53,7 @@
|
||||
// We mean it.
|
||||
//
|
||||
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
# include "QtCore/qt_windows.h"
|
||||
#endif
|
||||
#include "QtCore/qlibrary.h"
|
||||
@ -73,7 +73,7 @@ class QLibraryPrivate
|
||||
{
|
||||
public:
|
||||
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
HINSTANCE
|
||||
#else
|
||||
void *
|
||||
|
@ -176,12 +176,12 @@ QThreadPrivate::QThreadPrivate(QThreadData *d)
|
||||
{
|
||||
#if defined (Q_OS_UNIX)
|
||||
thread_id = 0;
|
||||
#elif defined (Q_WS_WIN)
|
||||
#elif defined (Q_OS_WIN)
|
||||
handle = 0;
|
||||
id = 0;
|
||||
waiters = 0;
|
||||
#endif
|
||||
#if defined (Q_WS_WIN) || defined (Q_OS_SYMBIAN)
|
||||
#if defined (Q_OS_WIN) || defined (Q_OS_SYMBIAN)
|
||||
terminationEnabled = true;
|
||||
terminatePending = false;
|
||||
#endif
|
||||
|
@ -51,7 +51,7 @@
|
||||
#if defined(Q_OS_WIN32) || defined(Q_OS_WINCE)
|
||||
#include <qt_windows.h>
|
||||
#endif
|
||||
#ifndef Q_WS_WIN
|
||||
#ifndef Q_OS_WIN
|
||||
#include <locale.h>
|
||||
#endif
|
||||
|
||||
@ -2519,7 +2519,7 @@ QString QDateTime::toString(Qt::DateFormat f) const
|
||||
}
|
||||
#ifndef QT_NO_TEXTDATE
|
||||
else if (f == Qt::TextDate) {
|
||||
#ifndef Q_WS_WIN
|
||||
#ifndef Q_OS_WIN
|
||||
buf = d->date.shortDayName(d->date.dayOfWeek());
|
||||
buf += QLatin1Char(' ');
|
||||
buf += d->date.shortMonthName(d->date.month());
|
||||
|
@ -66,7 +66,7 @@ QT_END_NAMESPACE
|
||||
#include "qstringlist.h"
|
||||
#include "qvariant.h"
|
||||
#include "qstringbuilder.h"
|
||||
#if defined(Q_WS_WIN)
|
||||
#if defined(Q_OS_WIN)
|
||||
# include "qt_windows.h"
|
||||
# include <time.h>
|
||||
#endif
|
||||
|
@ -52,7 +52,7 @@
|
||||
#include <qglobal.h>
|
||||
|
||||
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
# define _POSIX_
|
||||
# include <limits.h>
|
||||
# undef _POSIX_
|
||||
|
Loading…
Reference in New Issue
Block a user