| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
At this time, there are not yet any specialized handlers to
do anything specifically with tablet events; but we demonstrate
how to use HoverHandler to detect the type of stylus in use,
and how to use PointHandler to draw on a Canvas.
Unfortunately, events of types TabletEnterProximity and
TabletLeaveProximity are not delivered to the window, only to
QGuiApplication. So HoverHandler can detect when the stylus is moved
out of its parent Item (as long as it's still hovering over the tablet
surface), but cannot detect when the stylus leaves the tablet completely.
In Qt 5 that would require a custom application subclass
(see qtbase/examples/widgets/widgets/tablet/tabletapplication.cpp).
Fixes: QTBUG-79660
Change-Id: I81fdb99082dc41c0455085e6b6d3952402bf8742
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
| |
Change-Id: I16356ee214c80ff23c6b520c7ad492f86d85f986
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We already had a manual test using a slider, but that has only
one combination of DragHandler and TapHandler.
This test aims to test all possible combinations of DragHandler and
TapHandler together (as siblings, in different parts of the hierarcy,
with a Flickable beneath...)
We also show the current grabbers as an overlay over this entire
collection of manual tests.
Change-Id: Ic634d36d14f7456170f43b077fa72b03fb65bc18
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
| |
Change-Id: I598093647da3aba291945819d7c396a247fddf52
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
| |
Change-Id: I7f4783b6f9a5237ef6b8ae1a89fedaf9cdadffc5
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
|
| |
The background image is a POV-ray rendering which makes it look a bit
more like an actual joystick (but there's still no tilting stem under
the knob).
Change-Id: I9d130d6fcd72715733678a525c69785e5f1a52ea
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
It demonstrates that DragHandler's grabs work well enough, so that
you can grab the knob and drag it even while the cursor goes outside
the window. Also the TapHandler for detecting clicks or taps within
the "trough". And for completeness, the FakeFlickable example
needed scrollbars, to prove that it's possible to build all the
flicking and scrolling behaviors with only PointerHandlers.
Change-Id: I9d9323b1f583a02e0157edb85b6bffbe1652711f
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
| |
Add it to main.qml and it and its dependencies to resources
Add checkbox to control Flickable's pressDelay
Change-Id: Ifaa4bbbaf61944231ab80cf356d7a3c44b24d73b
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Until now it behaved as if this was set to DragThreshold: give up on
the tap as soon as you are clearly dragging rather than tapping.
But that's not what is normally wanted when building a Button control,
for example. So provide 3 options: give up past the drag threshold,
when the pointer goes outside the bounds, or when it's released
outside the bounds. The longPressThreshold also constrains all
three cases: holding (or dragging) for too long will not result
in an immediate cancellation, but it also will not be a tap gesture.
Change-Id: I95aec978e783892b55371391a27642751d91d9ff
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
| |
Device-agnostic tap/click detection. Also detect whether the
taps or clicks occur close enough together in both time and space
to be considered part of a multi-tap gesture.
Change-Id: I41a378feea3340b9f0409118273746a289641d6c
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
| |
This is a version of examples/quick/demos/photosurface updated to
use handlers instead of Areas.
Change-Id: I80a6c46f2ea4821097f3654cd885553aa484d405
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
| |
Demonstrate that DragHandler, MomentumAnimation and a couple of Items
are enough to implement most of Flickable's functionality.
Change-Id: I59dae38dc66c16813385aa6c00e3a1a834520f31
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
| |
It could be exposed as a new type of animation, but for now it's just
an experiment.
Change-Id: Ic900752a90ccae93270e27399f370f5d47495f74
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
| |
We can't copy the eventpoint and we can't continue to refer to it after
delivery, either. So we can't have an event property. Some QML use
cases depend on being able to access last-known values between events.
Change-Id: Ice8a1763015f2554275d0cb76824fd0366eaef56
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This allows the application developer to get the translation of the
dragged pointer, and apply it in a custom way.
This should usually be combined with setting target to null.
This will for instance be needed when we want to drag QtLocations map,
where a map is dragged by specifying the geo location of the center of the
map.
The map2.qml example demonstrates this.
Change-Id: I652d9fc92fa9b6dfd3796c7147832f25af0cc5bc
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
| |
The public-domain map is adapted from https://openclipart.org/detail/67039/
Change-Id: Ia3da049174a38a6cc9e9632eda4f4553ad16d3bf
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Similar to PinchArea but with improvements:
- Allows rotating and scaling about an arbitrary point rather than the center
- It's possible to require more than 2 fingers. E.g. maybe you use
3 fingers to manage a window, 2 fingers to manipulate content inside.
This could be achieved with two independent PinchHandlers.
Change-Id: Ifd40cfee115d7bc298378b26a58318bea40a8230
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
|
|
|
|
|
|
|
| |
A handler for dragging Items around by touch or mouse.
Change-Id: Id83fea568095eb6374f3f1abc6f550d81f3731df
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
|
|
QML manual tests will be added to test specific handlers later.
Change-Id: I691cff23f97fc79020d1090448e70a78de3b4be9
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
|