summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qgesture.cpp
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-07-10 11:23:07 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-07-10 11:23:07 (GMT)
commit8f84ccc8d16383e722f07578dbfa2b15c2b24431 (patch)
treeda2c590d7071ba535c41af00fe8ba310c8303e09 /src/gui/kernel/qgesture.cpp
parentcf907cb8ab5ecb95d964762c1cce586fa2207dff (diff)
parent6988f2bb36dafc2223c326b6fd21e49586b1379b (diff)
downloadQt-8f84ccc8d16383e722f07578dbfa2b15c2b24431.zip
Qt-8f84ccc8d16383e722f07578dbfa2b15c2b24431.tar.gz
Qt-8f84ccc8d16383e722f07578dbfa2b15c2b24431.tar.bz2
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (59 commits) Doc: Cleaning style and adding support for Creator Add NTLMv2 authentication support to QAuthenticator. QIODPLB: Sync behavior of ungetBlock() and ungetChar() QFileIconProvider: Load icons on demand. Doc: fixing offline style Fix handling of SSL certificates with wildcard domain names Doc: fixing examples link doc: Fixed several qdoc warnings. doc: Fixed several qdoc warnings. SSL library loading: load system libs only once Revert "SSL backend: load libraries for certificates only once" doc: Fixed several qdoc warnings. doc: Fixed several qdoc warnings. doc: Fixed several qdoc warnings. doc: Fixed several qdoc warnings. doc: Fixed several qdoc warnings. Doc: Adding support for Qt Creator style doc: Fixed last of the declarative/QML qdoc warnings. qdoc: Marked some missing declarative properties and functions as \internal. qhelpgenerator: Fix namespace syntax checking. ...
Diffstat (limited to 'src/gui/kernel/qgesture.cpp')
-rw-r--r--src/gui/kernel/qgesture.cpp29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/gui/kernel/qgesture.cpp b/src/gui/kernel/qgesture.cpp
index f5688f4..6359ecf 100644
--- a/src/gui/kernel/qgesture.cpp
+++ b/src/gui/kernel/qgesture.cpp
@@ -41,6 +41,7 @@
#include "qgesture.h"
#include "private/qgesture_p.h"
+#include "private/qstandardgestures_p.h"
#ifndef QT_NO_GESTURES
@@ -726,6 +727,34 @@ void QTapAndHoldGesture::setPosition(const QPointF &value)
d_func()->position = value;
}
+/*!
+ Set the timeout, in milliseconds, before the gesture triggers.
+
+ The recognizer will detect a touch down and and if \a msecs
+ later the touch is still down, it will trigger the QTapAndHoldGesture.
+ The default value is 700 milliseconds.
+*/
+// static
+void QTapAndHoldGesture::setTimeout(int msecs)
+{
+ QTapAndHoldGesturePrivate::Timeout = msecs;
+}
+
+/*!
+ Gets the timeout, in milliseconds, before the gesture triggers.
+
+ The recognizer will detect a touch down and and if timeout()
+ later the touch is still down, it will trigger the QTapAndHoldGesture.
+ The default value is 700 milliseconds.
+*/
+// static
+int QTapAndHoldGesture::timeout()
+{
+ return QTapAndHoldGesturePrivate::Timeout;
+}
+
+int QTapAndHoldGesturePrivate::Timeout = 700; // in ms
+
QT_END_NAMESPACE
#endif // QT_NO_GESTURES