aboutsummaryrefslogtreecommitdiffstats
path: root/src/quicktemplates2
diff options
context:
space:
mode:
Diffstat (limited to 'src/quicktemplates2')
-rw-r--r--src/quicktemplates2/qquickswipedelegate.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/quicktemplates2/qquickswipedelegate.cpp b/src/quicktemplates2/qquickswipedelegate.cpp
index 3669ce05..4b16609d 100644
--- a/src/quicktemplates2/qquickswipedelegate.cpp
+++ b/src/quicktemplates2/qquickswipedelegate.cpp
@@ -697,6 +697,11 @@ void QQuickSwipe::close()
if (qFuzzyIsNull(d->position))
return;
+ if (d->control->isPressed()) {
+ // We don't support closing when we're pressed; release() or clicked() should be used instead.
+ return;
+ }
+
d->beginTransition(0.0);
d->wasComplete = false;
d->positionBeforePress = 0.0;