diff options
author | Liang Qi <liang.qi@qt.io> | 2017-01-30 12:39:22 +0100 |
---|---|---|
committer | Liang Qi <liang.qi@qt.io> | 2017-01-30 12:46:20 +0100 |
commit | 246799d8a7bf42c1f22fca7ef6d77e8d58054bad (patch) | |
tree | a0b92a804d7d2a30cd68fa327df5777d8bcc36ba /src/gui/kernel | |
parent | 5ad191850becd7dc1d61d0975f141a5db64e6373 (diff) | |
parent | 02cc57f4edbae450ecfa8368052afa44f8aeee19 (diff) |
Merge remote-tracking branch 'origin/5.8' into dev
Conflicts:
examples/network/network-chat/peermanager.cpp
src/widgets/util/qsystemtrayicon.cpp
src/widgets/util/qsystemtrayicon_qpa.cpp
src/widgets/util/qsystemtrayicon_win.cpp
src/widgets/util/qsystemtrayicon_x11.cpp
Change-Id: I1c026df83818c0ccaf956980370e7522960627db
Diffstat (limited to 'src/gui/kernel')
-rw-r--r-- | src/gui/kernel/qguiapplication.cpp | 9 | ||||
-rw-r--r-- | src/gui/kernel/qplatformdialoghelper.cpp | 2 |
2 files changed, 5 insertions, 6 deletions
diff --git a/src/gui/kernel/qguiapplication.cpp b/src/gui/kernel/qguiapplication.cpp index 2faf970855..e4eabc815e 100644 --- a/src/gui/kernel/qguiapplication.cpp +++ b/src/gui/kernel/qguiapplication.cpp @@ -2474,7 +2474,7 @@ void QGuiApplicationPrivate::processTouchEvent(QWindowSystemInterfacePrivate::To QWindow *window = e->window.data(); typedef QPair<Qt::TouchPointStates, QList<QTouchEvent::TouchPoint> > StatesAndTouchPoints; QHash<QWindow *, StatesAndTouchPoints> windowsNeedingEvents; - bool velocityOnly = false; + bool stationaryTouchPointChangedVelocity = false; for (int i = 0; i < e->points.count(); ++i) { QTouchEvent::TouchPoint touchPoint = e->points.at(i); @@ -2554,7 +2554,7 @@ void QGuiApplicationPrivate::processTouchEvent(QWindowSystemInterfacePrivate::To if (touchPoint.state() == Qt::TouchPointStationary) { if (touchInfo.touchPoint.velocity() != touchPoint.velocity()) { touchInfo.touchPoint.setVelocity(touchPoint.velocity()); - velocityOnly = true; + stationaryTouchPointChangedVelocity = true; } } else { touchInfo.touchPoint = touchPoint; @@ -2595,10 +2595,9 @@ void QGuiApplicationPrivate::processTouchEvent(QWindowSystemInterfacePrivate::To break; case Qt::TouchPointStationary: // don't send the event if nothing changed - if (velocityOnly) - eventType = QEvent::TouchUpdate; - else + if (!stationaryTouchPointChangedVelocity) continue; + Q_FALLTHROUGH(); default: eventType = QEvent::TouchUpdate; break; diff --git a/src/gui/kernel/qplatformdialoghelper.cpp b/src/gui/kernel/qplatformdialoghelper.cpp index 16f31db50d..01cf98c7c9 100644 --- a/src/gui/kernel/qplatformdialoghelper.cpp +++ b/src/gui/kernel/qplatformdialoghelper.cpp @@ -278,7 +278,7 @@ void QColorDialogStaticData::readSettings() void QColorDialogStaticData::writeSettings() const { #ifndef QT_NO_SETTINGS - if (!customSet) { + if (customSet) { QSettings settings(QSettings::UserScope, QStringLiteral("QtProject")); for (int i = 0; i < int(CustomColorCount); ++i) settings.setValue(QLatin1String("Qt/customColors/") + QString::number(i), customRgb[i]); |