QApplication: Fix MSVC-warning about unused variable q.

Change-Id: I44f34816cb18583fcbbab0a6c79b313a829d9236
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
bb10
Friedemann Kleint 2013-03-07 16:41:39 +01:00 committed by The Qt Project
parent da672eba99
commit 323a2bff2c
1 changed files with 2 additions and 6 deletions

View File

@ -603,10 +603,8 @@ void QApplicationPrivate::initialize()
is_app_running = true; // no longer starting up
Q_Q(QApplication);
if (qgetenv("QT_USE_NATIVE_WINDOWS").toInt() > 0)
q->setAttribute(Qt::AA_NativeWindows);
QCoreApplication::setAttribute(Qt::AA_NativeWindows);
#ifdef Q_OS_WINCE
#ifdef QT_AUTO_MAXIMIZE_THRESHOLD
@ -3777,8 +3775,6 @@ private:
bool QApplicationPrivate::translateTouchToMouse(QWidget *widget, QTouchEvent *event)
{
Q_Q(QApplication);
// Check if the platform wants synthesized mouse events.
if (!QGuiApplicationPrivate::platformIntegration()->styleHint(QPlatformIntegration::SynthesizeMouseFromTouchEvents).toBool())
return false;
@ -3809,7 +3805,7 @@ bool QApplicationPrivate::translateTouchToMouse(QWidget *widget, QTouchEvent *ev
// Note it has to be a spontaneous event if we want the focus management
// and input method support to behave properly. Quite some of the code
// related to those aspect check for the spontaneous flag.
const bool res = q->sendSpontaneousEvent(widget, &mouseEvent);
const bool res = QCoreApplication::sendSpontaneousEvent(widget, &mouseEvent);
event->setAccepted(mouseEvent.isAccepted());
if (mouseEvent.isAccepted())