QSensorGestureRecognizer Class
The QSensorGestureRecognizer class is the base class for a sensor gesture recognizer. More...
Header: | #include <QSensorGestureRecognizer> |
qmake: | QT += sensors |
Since: | Qt 5.1 |
Inherits: | QObject |
This class was introduced in Qt 5.1.
Public Functions
QSensorGestureRecognizer(QObject *parent = Q_NULLPTR) | |
virtual | ~QSensorGestureRecognizer() |
void | createBackend() |
QStringList | gestureSignals() const |
void | startBackend() |
void | stopBackend() |
- 16 public functions inherited from QObject
Related Non-Members
typedef | QObjectList |
Macros
QT_NO_NARROWING_CONVERSIONS_IN_CONNECT | |
Q_CLASSINFO(Name, Value) | |
Q_DISABLE_COPY(Class) | |
Q_DISABLE_COPY_MOVE(Class) | |
Q_DISABLE_MOVE(Class) | |
Q_EMIT | |
Q_ENUM(...) | |
Q_ENUM_NS(...) | |
Q_FLAG(...) | |
Q_FLAG_NS(...) | |
Q_GADGET | |
Q_INTERFACES(...) | |
Q_INVOKABLE | |
Q_NAMESPACE | |
Q_OBJECT | |
Q_PROPERTY(...) | |
Q_REVISION | |
Q_SET_OBJECT_NAME(Object) | |
Q_SIGNAL | |
Q_SIGNALS | |
Q_SLOT | |
Q_SLOTS |
Additional Inherited Members
- 1 property inherited from QObject
- 1 public slot inherited from QObject
- 1 signal inherited from QObject
- 5 static public members inherited from QObject
- 8 protected functions inherited from QObject
Detailed Description
QSensorGesture recognizer developers should sub-class this to implement their own recognizer.
All sensor gesture recognizers have a detected(QString) signal. Implementors can use this and send recognizer specific gestures, such as detected("shake_left") or implement custom signals such as shakeLeft().
These custom signals will be available in the QSensorGesture object at runtime.
See also QSensorGestureRecognizer::gestureSignals().
Member Function Documentation
QSensorGestureRecognizer::QSensorGestureRecognizer(QObject *parent = Q_NULLPTR)
Constructs the QSensorGestureRecognizer with parent as parent.
[virtual]
QSensorGestureRecognizer::~QSensorGestureRecognizer()
Destroy the QSensorGestureRecognizer
void QSensorGestureRecognizer::createBackend()
Calls QSensorGestureRecognizer::create() if the recognizer is valid.
QStringList QSensorGestureRecognizer::gestureSignals() const
Returns a list of signals that this recognizer supports.
Note that all signals declared will be exported to the QSensorGesture object. If you need to use signals that are not exported, you should use a private class to do so.
void QSensorGestureRecognizer::startBackend()
Calls QSensorGestureRecognizer::start() if the recognizer isn't already initialized. This is called by the QSensorGesture object, so please use that instead.
See also QSensorGesture::startDetection().
void QSensorGestureRecognizer::stopBackend()
Calls QSensorGestureRecognizer::stop() if no other clients are using it. This is called by the QSensorGesture object, so please use that instead.
See also QSensorGesture::stopDetection().