summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qeventpoint_p.h
Commit message (Collapse)AuthorAgeFilesLines
* Make QEventPoint an idiomatic value typeVolker Hilsheimer2020-11-161-2/+3
| | | | | | | | | | | | | | | | | | Use atomic ref counting and make type movable. Make a moved-from QEventPoint valid but undefined. Given that the d pointer is anyway loaded into the register, the additional check doesn't cost much, and makes the class more compliant with our guide for value types in Qt. Add a free swap overload via Q_DECLARED_SHARED, which also declares the type as movable. As a drive-by, remove superfluous inline. This also silences some static analyser warnings. Change-Id: I7c4a436fce44556aa37026ac26dc2061e1f01de9 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Move QEventPoint and QPointingDeviceUniqueId out of qeventVolker Hilsheimer2020-11-071-0/+200
qevent.h/cpp are huge already, no need for more classes. Move QEventPoint into new qeventpoint.h/cpp files, and QPointingDeviceUniqueId into qpointingdevice.cpp; the class is already declared in qpointingdevice.h. Move the documentation of QEventPoint APIs next to the implementation, and document all APIs as properties. Add Q_PROPERTY macro where missing. QEventPoint::device needs a workaround of qdoc due to the type being a pointer-to-const; qdoc doesn't know how to tie a \property to it, but documents it correctly. While at it, move the logging category declarations to the header matching the .cpp file where they are defined. Change-Id: I096e609edbb760b5686d577e7fe47eea0807904e Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>