QMouseHandler Class
class Qt3DInput::QMouseHandlerProvides a means of being notified about mouse events when attached to a QMouseDevice instance. More...
Header: | #include <Qt3DInput/QMouseHandler> |
qmake: | QT += 3dinput |
Since: | Qt 5.5 |
Instantiated By: | MouseHandler |
Inherits: | Qt3DCore::QComponent |
This class was introduced in Qt 5.5.
Public Functions
QMouseHandler(Qt3DCore::QNode *parent = nullptr) | |
void | setSourceDevice(Qt3DInput::QMouseDevice *mouseDevice) |
Protected Functions
void | clicked(Qt3DInput::QMouseEvent *mouse) |
void | doubleClicked(Qt3DInput::QMouseEvent *mouse) |
void | entered() |
void | exited() |
void | positionChanged(Qt3DInput::QMouseEvent *mouse) |
void | pressAndHold(Qt3DInput::QMouseEvent *mouse) |
void | pressed(Qt3DInput::QMouseEvent *mouse) |
void | released(Qt3DInput::QMouseEvent *mouse) |
Detailed Description
Note: QMouseHandler components shouldn't be shared, not respecting that condition will most likely result in undefined behaviors.
See also QMouseDevice and QMouseEvent.
Member Function Documentation
QMouseHandler::QMouseHandler(Qt3DCore::QNode *parent = nullptr)
Constructs a new QMouseHandler instance with parent parent.
[protected]
void QMouseHandler::clicked(Qt3DInput::QMouseEvent *mouse)
This signal is emitted when a mouse button is clicked with the event details being contained within mouse.
[protected]
void QMouseHandler::doubleClicked(Qt3DInput::QMouseEvent *mouse)
This signal is emitted when a mouse button is double clicked with the event details being contained within mouse.
[protected]
void QMouseHandler::entered()
[protected]
void QMouseHandler::exited()
[protected]
void QMouseHandler::positionChanged(Qt3DInput::QMouseEvent *mouse)
This signal is emitted when the mouse position changes with the event details being contained within mouse
[protected]
void QMouseHandler::pressAndHold(Qt3DInput::QMouseEvent *mouse)
This signal is emitted when a mouse button is pressed and held down with the event details being contained within mouse
[protected]
void QMouseHandler::pressed(Qt3DInput::QMouseEvent *mouse)
This signal is emitted when a mouse button is pressed with the event details being contained within mouse
[protected]
void QMouseHandler::released(Qt3DInput::QMouseEvent *mouse)
This signal is emitted when a mouse button is released with the event details being contained within mouse
void QMouseHandler::setSourceDevice(Qt3DInput::QMouseDevice *mouseDevice)
Sets the mouse device of the QMouseHandler instance to mouseDevice.