aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquickmultipointtoucharea_p.h
Commit message (Collapse)AuthorAgeFilesLines
* Mark non-notifying properties in event types CONSTANTShawn Rutledge2018-08-061-2/+2
| | | | | | | | | | | | | | Event objects are valid only within the context of a JS callback that receives the object as a signal parameter, and the object will not change during the runtime of that callback. It's not true that the properties will never change, because event objects are pooled and reused; but the QML is not allowed to keep a reference to an event, so the property changes during this reuse are not meant to be seen. QQuickMouseEvent is similar, and its properties were already marked CONSTANT. Change-Id: I4985e4a27bf192779629311eb8c6c1f63d22df3e Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* init variables where they are declared when possible (clang-tidy)Shawn Rutledge2018-02-261-25/+16
| | | | | | | | clang-tidy -p compile_commands.json $file -checks='-*,modernize-use-default-member-init,readability-redundant-member-init' -config='{CheckOptions: [{key: modernize-use-default-member-init.UseAssignment, value: "1"}]}' -header-filter='qtdeclarative' -fix Change-Id: I705f3235ff129ba68b0d8dad54a083e29fcead5f Reviewed-by: Johan Helsing <johan.helsing@qt.io>
* use nullptr consistently (clang-tidy)Shawn Rutledge2018-02-261-2/+2
| | | | | | | | | | | | | From now on we prefer nullptr instead of 0 to clarify cases where we are assigning or testing a pointer rather than a numeric zero. Also, replaced cases where 0 was passed as Qt::KeyboardModifiers with Qt::NoModifier (clang-tidy replaced them with nullptr, which waas wrong, so it was just as well to make the tests more readable rather than to revert those lines). Change-Id: I4735d35e4d9f42db5216862ce091429eadc6e65d Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Replace Q_DECL_OVERRIDE with overrideKevin Funk2017-09-251-10/+10
| | | | | Change-Id: I176f91a8c51e81a2df3fe91733118261491223ee Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* MultiPointTouchArea.TouchPoint: add rotation, uniqueId and ellipseDiametersShawn Rutledge2017-01-041-0/+19
| | | | | | | | | So far uniqueId and rotation are mainly applicable to TUIO. Deprecate the area property in favor of ellipseDiameters. Also improve the mpta-crosshairs manual test to show this information. Change-Id: I16ea6618ae21ce66dac45638d6e2bb3c0a3b1818 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* Rename parameter i to receiver in ↵Frederik Gladhorn2016-10-041-1/+1
| | | | | | | QQuickMultiPointTouchArea::childMouseEventFilter Change-Id: I7b936bd13d9e797ea4ed76a72ae1ff87b0d5b640 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Quick: use const (and const APIs) moreAnton Kudryavtsev2016-08-121-1/+1
| | | | | | | | For CoW types, prefer const methods to avoid needless detach()ing. Change-Id: I270cdc6eb8c5946f5c20b379bbb7c60f0ba518eb Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Updated license headersJani Heikkinen2016-01-191-14/+20
| | | | | | | | | | | From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new LGPL header instead of LGPL21 one (in those files which will be under LGPL v3) Change-Id: Ic36f1a0a1436fe6ac6eeca8c2375a79857e9cb12 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Initialize _startX and _startYAlbert Astals Cid2015-12-011-0/+1
| | | | | | | | Otherwise valgrind complains about "Conditional jump or move depends on uninitialised value(s)" Change-Id: If1cc6f2839799a80dde5106700bb26fda4b357c3 Reviewed-by: Michael Brasser <michael.brasser@live.com>
* Add missing "We mean it" comments to private headers.Friedemann Kleint2015-10-061-0/+11
| | | | | | Task-number: QTBUG-48594 Change-Id: Ifc207938de7f0c8995fc712df92665f222612647 Reviewed-by: Alan Alpert <aalpert@blackberry.com>
* Fix invocations of static methods of QGuiApplication/QCoreApplication.Friedemann Kleint2015-03-051-1/+1
| | | | | Change-Id: I7bcc209b0c6e77cf6d974af85a19487345a48975 Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
* Update copyright headersJani Heikkinen2015-02-121-7/+7
| | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Change-Id: I61120571787870c0ed17066afb31779b1e6e30e9 Reviewed-by: Iikka Eklund <iikka.eklund@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.4' into devOswald Buddenhagen2014-09-111-19/+11
|\ | | | | | | | | | | | | | | | | Conflicts: src/quick/items/qquickpainteditem.h src/quick/items/qquickshadereffectsource.cpp src/quick/items/qquickshadereffectsource_p.h Change-Id: If98096443afe85fc4370cef971eace050006a61b
| * Update license headers and add new licensesJani Heikkinen2014-08-251-19/+11
| | | | | | | | | | | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 & LICENSE.GPLv2 - Removed LICENSE.GPL Change-Id: I84a565e2e0caa3b76bf291a7d188a57a4b00e1b0 Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
* | Add Q_DECL_OVERRIDEAlbert Astals Cid2014-08-141-10/+10
|/ | | | | Change-Id: I2e64950aef710f943c3bc50bc9bf8a1f7fb58d28 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* MultiPointTouchArea: Guard _mouseTouchPoint with a QPointer.Robin Burchell2014-08-081-1/+2
| | | | | | | | | | | | The touch point can be deleted (for instance, on ungrab()) without _mouseTouchPoint being reset occurs. This caused a crash on tst_qquickmultipointtoucharea::inFlickable with MallocScribble=1 enabled on OS X (use-after-free). Change-Id: Ife9f59d75827285b18bb1772ddbee30d79a3f0b5 Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* MultiPointTouchArea: handles mouse too, unless mouseEnabled is falseShawn Rutledge2014-03-101-0/+10
| | | | | | | | | | | | | | | | | | | A new boolean property mouseEnabled is introduced (true by default). If set to true, then it will handle any non-synthetic mouse event as if it were a touch point. If set to false, the area becomes transparent for real mouse events so that a MultiPointTouchArea can be stacked on top of a MouseArea in order to separate handling of touch and mouse. In either case it continues to absorb and ignore synthesized mouse events (including touch-to-mouse synthesis in QQuickWindow). [ChangeLog][QtQuick][MultiPointTouchArea]handles mouse as a touchpoint; added mouseEnabled property to permit transparent pass-through to mouse-sensitive items Change-Id: I4af94d838f0060154494589c0f15c6858ee89ddb Task-number: QTBUG-31047 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Improve Mac OS X touch event enabling.Morten Johan Sørvig2014-01-171-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | Previously, the Qt Quick touch interaction items would enable touch events on window change. On app startup this would typically happen before the platform window was created, and the call to registerTouchWindow would then create the platform window. registerTouchWindow in QtBase has now been changed to not create the platform window since this has unwanted side effects. Calling it at window change time will then have no effect for the initial window change. Enable and disable touch events on hoverEnter/Leave instead. This is similar to what QtWidgets does and has an additional benefit: touch events can now be enabled when the mouse cursor is hovering over a touch item, reducing the chances of it interfering with scroll events for other items. Task-number: QTBUG-32988 Change-Id: Ic48dbec910f52299d5068f5ca7508be73cdc6f36 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* Fix license headers of QtQuick sources.Gunnar Sletta2013-09-301-1/+1
| | | | | Change-Id: I3750c47640bf21c3567c5fa1c4667e3e2552942e Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Allow QtQuick private headers to be used with QT_NO_KEYWORDS.Jocelyn Turcotte2013-09-121-1/+1
| | | | | | | | | | | This is necessary for the QtWebEngine module. This also adds an empty nokeywords test using the same mechanism as qtbase/tests/auto/tools/moc/no-keywords.h to find conflicts at compile time. Change-Id: I9df541720797dd61f078178c2af68ead18ff8bfe Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Enable touch events on Mac for MultiPointTouchAreaMorten Johan Sørvig2013-05-031-0/+4
| | | | | | | | | | | | | | Enabling touch events on a window causes scroll event lag so we want to avoid avoid it as far as possible. Enable/disable on scene changes, similar to what we do for WA_AcceptTouchEvents for widgets. Task-number: QTBUG-28483 Change-Id: I2e5b5e2b093cccfc5253f7228f5ec0c588c60371 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Remove QT_{BEGIN,END}_HEADER macro usageSergio Ahumada2013-01-281-4/+0
| | | | | | | | | | | The macro was made empty in qtbase/ba3dc5f3b56d1fab6fe37fe7ae08096d7dc68bcb and is no longer necessary or used. Discussed-on: http://lists.qt-project.org/pipermail/development/2013-January/009284.html Change-Id: Ia07e99676e0134fde5e32880edb95e57c779a7ff Reviewed-by: Laszlo Papp <lpapp@kde.org> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com> Reviewed-by: Alan Alpert <aalpert@rim.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-101-1/+1
| | | | | | Change-Id: I6c3bd7bebe3d62d1cfd0fa6334544c9db8398c76 Reviewed-by: Akseli Salovaara <akseli.salovaara@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-231-24/+24
| | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: Ie7f5d49ed8235d7a7845ab68f99ad1c220e64d5c Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Remove deprectated MultiPointTouchArea signals.Michael Brasser2012-05-231-6/+0
| | | | | Change-Id: Icea6d17704b2ddb7917bc0c0fea11dd625562685 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* Rename QDeclarative symbols to QQuick and QQmlMatthew Vogt2012-02-241-10/+10
| | | | | | | | | | | | | Symbols beginning with QDeclarative are already exported by the quick1 module. Users can apply the bin/rename-qtdeclarative-symbols.sh script to modify client code using the previous names of the renamed symbols. Task-number: QTBUG-23737 Change-Id: Ifaa482663767634931e8711a8e9bf6e404859e66 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Add velocity data to TouchPointMichael Brasser2012-02-171-0/+6
| | | | | Change-Id: I0555b3ad41e8c08563188e1ba9190e54d4bb3784 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Provide visual debugging for MouseArea and TouchAreaYann Bodson2012-02-171-0/+1
| | | | | | | | | Display MouseAreas and TouchAreas as semi transparent rectangles when the environment variable QML_VISUAL_TOUCH_DEBUGGING is set. Task-number: QTBUG-24283 Change-Id: Iec8482a79ed1d4b802c29a5f7104af4e0a6eab7d Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: If39bd256b0fa85eba17ea30f8ab87ea27d758908 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update obsolete contact address.Jason McDonald2012-01-231-1/+1
| | | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I6a730abc0c396fb545a48b2d6938abedac2e3f1c Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com> Reviewed-by: Alan Alpert <alan.alpert@nokia.com>
* Update copyright year in license headers.Jason McDonald2012-01-051-1/+1
| | | | | Change-Id: I0a8d99909cac867dce72da70b1bbcb649989a51b Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Simplify MultiPointTouchArea signal names.Michael Brasser2012-01-031-4/+10
| | | | | Change-Id: I0617bf7138b76495c111739e2cbdf3b77c4b6a5d Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
* Add a pressed property to TouchPoint.Michael Brasser2011-12-231-8/+12
| | | | | | | | | | | Remove the valid property, and replace it with pressed. The semantics have changed slightly for a release -- pressed will immediately become false, whereas valid remained true until the next touch event. Also make sure touch information is correctly updated on release. Change-Id: Ic61e1b6884c67f19100a6f8fc218b8b05b291ff0 Reviewed-by: Alan Alpert <alan.alpert@nokia.com>
* Say hello to QtQuick moduleKent Hansen2011-12-021-0/+265
This change moves the QtQuick 2 types and C++ API (including SceneGraph) to a new module (AKA library), QtQuick. 99% of this change is moving files from src/declarative to src/quick, and from tests/auto/declarative to tests/auto/qtquick2. The loading of QtQuick 2 ("import QtQuick 2.0") is now delegated to a plugin, src/imports/qtquick2, just like it's done for QtQuick 1. All tools, examples, and tests that use QtQuick C++ API have gotten "QT += quick" or "QT += quick-private" added to their .pro file. A few additional internal QtDeclarative classes had to be exported (via Q_DECLARATIVE_PRIVATE_EXPORT) since they're needed by the QtQuick 2 implementation. The old header locations (e.g. QtDeclarative/qquickitem.h) will still be supported for some time, but will produce compile-time warnings. (To avoid the QtQuick implementation using the compatibility headers (since QtDeclarative's includepath comes first), a few include statements were modified, e.g. from "#include <qsgnode.h>" to "#include <QtQuick/qsgnode.h>".) There's a change in qtbase that automatically adds QtQuick to the module list if QtDeclarative is used. Together with the compatibility headers, this should help reduce the migration pain for existing projects. In theory, simply getting an existing QtDeclarative-based project to compile and link shouldn't require any changes for now -- but porting to the new scheme is of course recommended, and will eventually become mandatory. Task-number: QTBUG-22889 Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Change-Id: Ia52be9373172ba2f37e7623231ecb060316c96a7 Reviewed-by: Kent Hansen <kent.hansen@nokia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>