QGestureManager: port Q_FOREACH to ranged-for [5/6]
getGestureTargets() first parameter is a QSet created locally at the call site in deliverEvents(); and the loop body doesn't change it. Change-Id: I3484f7ecc9d85b22b45a123ccf75316d5316e031 Task-number: QTBUG-115803 Reviewed-by: Marc Mutz <marc.mutz@qt.io>
This commit is contained in:
parent
cce946b3aa
commit
2309b38a64
@ -550,7 +550,7 @@ void QGestureManager::getGestureTargets(const QSet<QGesture*> &gestures,
|
|||||||
GestureByTypes gestureByTypes;
|
GestureByTypes gestureByTypes;
|
||||||
|
|
||||||
// sort gestures by types
|
// sort gestures by types
|
||||||
foreach (QGesture *gesture, gestures) {
|
for (QGesture *gesture : gestures) {
|
||||||
QWidget *receiver = m_gestureTargets.value(gesture, nullptr);
|
QWidget *receiver = m_gestureTargets.value(gesture, nullptr);
|
||||||
Q_ASSERT(receiver);
|
Q_ASSERT(receiver);
|
||||||
if (receiver)
|
if (receiver)
|
||||||
|
Loading…
Reference in New Issue
Block a user