diff options
author | Thierry Bastian <thierry.bastian@nokia.com> | 2009-09-02 14:23:44 (GMT) |
---|---|---|
committer | Thierry Bastian <thierry.bastian@nokia.com> | 2009-09-02 14:24:35 (GMT) |
commit | 0f06310ad141fb3705cb5180db700aa82a155287 (patch) | |
tree | dbd32a3abecbe2189b1cb6271a8730f0f2e5c204 | |
parent | 9b7b54f72278249984565d67ebac6b2700c3d002 (diff) | |
download | Qt-0f06310ad141fb3705cb5180db700aa82a155287.zip Qt-0f06310ad141fb3705cb5180db700aa82a155287.tar.gz Qt-0f06310ad141fb3705cb5180db700aa82a155287.tar.bz2 |
fix warnings on mingw
-rw-r--r-- | src/corelib/statemachine/qsignaltransition.cpp | 14 | ||||
-rw-r--r-- | src/gui/painting/qdrawhelper_mmx_p.h | 2 | ||||
-rw-r--r-- | src/gui/painting/qdrawhelper_sse2.cpp | 2 | ||||
-rw-r--r-- | src/gui/painting/qdrawhelper_sse_p.h | 2 | ||||
-rw-r--r-- | src/gui/styles/qcommonstyle.cpp | 4 | ||||
-rw-r--r-- | src/script/bridge/qscriptqobject.cpp | 1 | ||||
-rw-r--r-- | src/svg/qgraphicssvgitem.h | 1 |
7 files changed, 13 insertions, 13 deletions
diff --git a/src/corelib/statemachine/qsignaltransition.cpp b/src/corelib/statemachine/qsignaltransition.cpp index ac2aac8..2fc6a58 100644 --- a/src/corelib/statemachine/qsignaltransition.cpp +++ b/src/corelib/statemachine/qsignaltransition.cpp @@ -249,17 +249,15 @@ void QSignalTransitionPrivate::callOnTransition(QEvent *e) { Q_Q(QSignalTransition); - QSignalEvent *se = static_cast<QSignalEvent *>(e); - int savedSignalIndex; if (e->type() == QEvent::Signal) { - savedSignalIndex = se->m_signalIndex; + QSignalEvent *se = static_cast<QSignalEvent *>(e); + int savedSignalIndex = se->m_signalIndex; se->m_signalIndex = originalSignalIndex; - } - - q->onTransition(e); - - if (e->type() == QEvent::Signal) + q->onTransition(e); se->m_signalIndex = savedSignalIndex; + } else { + q->onTransition(e); + } } QT_END_NAMESPACE diff --git a/src/gui/painting/qdrawhelper_mmx_p.h b/src/gui/painting/qdrawhelper_mmx_p.h index e107c72..68d9ec0 100644 --- a/src/gui/painting/qdrawhelper_mmx_p.h +++ b/src/gui/painting/qdrawhelper_mmx_p.h @@ -65,7 +65,7 @@ #define C_80 const m64 mmx_0x0080 = _mm_set1_pi16(0x80) #define C_00 const m64 mmx_0x0000 = _mm_setzero_si64() -#if defined(Q_OS_WIN) +#ifdef Q_CC_MSVC # pragma warning(disable: 4799) // No EMMS at end of function #endif diff --git a/src/gui/painting/qdrawhelper_sse2.cpp b/src/gui/painting/qdrawhelper_sse2.cpp index 5e8fce5..32a8432 100644 --- a/src/gui/painting/qdrawhelper_sse2.cpp +++ b/src/gui/painting/qdrawhelper_sse2.cpp @@ -183,7 +183,7 @@ void qt_bitmapblit16_sse2(QRasterBuffer *rasterBuffer, int x, int y, const int destStride = rasterBuffer->bytesPerLine() / sizeof(quint16); const __m128i c128 = _mm_set1_epi16(c); -#if defined(Q_OS_WIN) +#if defined(Q_CC_MSVC) # pragma warning(disable: 4309) // truncation of constant value #endif const __m128i maskmask = _mm_set_epi16(0x0101, 0x0202, 0x0404, 0x0808, diff --git a/src/gui/painting/qdrawhelper_sse_p.h b/src/gui/painting/qdrawhelper_sse_p.h index dd75bd9..23b629e 100644 --- a/src/gui/painting/qdrawhelper_sse_p.h +++ b/src/gui/painting/qdrawhelper_sse_p.h @@ -132,7 +132,7 @@ inline void qt_bitmapblit16_sse_template(QRasterBuffer *rasterBuffer, const int destStride = rasterBuffer->bytesPerLine() / sizeof(quint16); const __m64 c64 = _mm_set1_pi16(c); -#if defined(Q_OS_WIN) +#ifdef Q_CC_MSVC # pragma warning(disable: 4309) // truncation of constant value #endif const __m64 maskmask1 = _mm_set_pi16(0x1010, 0x2020, 0x4040, 0x8080); diff --git a/src/gui/styles/qcommonstyle.cpp b/src/gui/styles/qcommonstyle.cpp index c9bdb7f..41f9ec0 100644 --- a/src/gui/styles/qcommonstyle.cpp +++ b/src/gui/styles/qcommonstyle.cpp @@ -5219,7 +5219,7 @@ QPixmap QCommonStyle::standardPixmap(StandardPixmap sp, const QStyleOption *opti Q_UNUSED(sp); #else QPixmap pixmap; - const bool rtl = (option && option->direction == Qt::RightToLeft) || !option && QApplication::isRightToLeft(); + const bool rtl = (option && option->direction == Qt::RightToLeft) || (!option && QApplication::isRightToLeft()); if (QApplication::desktopSettingsAware() && !QIcon::themeName().isEmpty()) { switch (sp) { @@ -5509,7 +5509,7 @@ QIcon QCommonStyle::standardIconImplementation(StandardPixmap standardIcon, cons const QWidget *widget) const { QIcon icon; - const bool rtl = (option && option->direction == Qt::RightToLeft) || !option && QApplication::isRightToLeft(); + const bool rtl = (option && option->direction == Qt::RightToLeft) || (!option && QApplication::isRightToLeft()); if (QApplication::desktopSettingsAware() && !QIcon::themeName().isEmpty()) { switch (standardIcon) { case SP_DirHomeIcon: diff --git a/src/script/bridge/qscriptqobject.cpp b/src/script/bridge/qscriptqobject.cpp index 0592a89..bd5d161 100644 --- a/src/script/bridge/qscriptqobject.cpp +++ b/src/script/bridge/qscriptqobject.cpp @@ -1869,6 +1869,7 @@ JSC::JSValue QMetaObjectWrapperObject::execute(JSC::ExecState *exec, QScriptContext *ctx = eng_p->contextForFrame(exec); JSC::CallData callData; JSC::CallType callType = data->ctor.getCallData(callData); + Q_UNUSED(callType); Q_ASSERT_X(callType == JSC::CallTypeHost, Q_FUNC_INFO, "script constructors not supported"); if (data->ctor.isObject(&FunctionWithArgWrapper::info)) { FunctionWithArgWrapper *wrapper = static_cast<FunctionWithArgWrapper*>(JSC::asObject(data->ctor)); diff --git a/src/svg/qgraphicssvgitem.h b/src/svg/qgraphicssvgitem.h index e8065da..d51095c 100644 --- a/src/svg/qgraphicssvgitem.h +++ b/src/svg/qgraphicssvgitem.h @@ -58,6 +58,7 @@ class QGraphicsSvgItemPrivate; class Q_SVG_EXPORT QGraphicsSvgItem : public QObject, public QGraphicsItem { Q_OBJECT + Q_INTERFACES(QGraphicsItem) public: QGraphicsSvgItem(QGraphicsItem *parentItem=0); |