aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquickflickable.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-08-171-3/+7
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/compiler/qqmltypecompiler.cpp src/qml/compiler/qv4isel_moth.cpp src/qml/compiler/qv4ssa_p.h src/qml/qml/qqmlobjectcreator.cpp Change-Id: I8bb7fe773d657f908f20ee5e72c2b9bd643f6260
| | * | Doc: mention when Flickable.AutoFlickIfNeeded was addedJ-P Nurmi2016-08-151-1/+1
| | | | | | | | | | | | | | | | | | | | Change-Id: Icf72c05c9573715771353bd03735f64eadd808f2 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-08-131-2/+6
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/compiler/qv4isel_moth.cpp src/qml/compiler/qv4ssa_p.h tests/benchmarks/qml/qqmlimage/qqmlimage.pro tests/benchmarks/qml/qqmlimage/tst_qqmlimage.cpp Change-Id: Iad11ce7fdf0c6d200fdebc16a94081bd8069a87a
| | | * Flickable: avoid infinite velocity during release after dragShawn Rutledge2016-08-051-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It sometimes happens on touchscreens that mouse events occur too close together. We cannot calculate velocity based on zero elapsed time, so just ignore the event. Task-number: QTBUG-45527 Change-Id: I120e73cfa60e2fcc594cb1f3b69f530e746abddd Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
* | | | Introduce QQuickPointerHandler: base class for nested event handlersShawn Rutledge2016-08-151-0/+3
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | They will be Tech Preview in 5.8, so they shouldn't be available unless you explicitly import them. Task-number: QTBUG-54824 Change-Id: I290854a4e2b76e2cdfef5c216c7fdeb47fbcd390 Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
* | | Merge remote-tracking branch 'origin/5.7' into devEdward Welbourne2016-08-021-2/+2
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/quick/items/qquickshadereffect.cpp 5.7 had a bug-fix in code dev has replaced wholesale. src/quick/items/qquickwindow.cpp src/quick/items/qquickwindow_p.h One side changed a method's signature; the other side renamed a method declared adjacent to it and changed some code using it, moving some from the public class to its private partner. tests/auto/qml/debugger/qqmlprofilerservice/tst_qqmlprofilerservice.cpp One side added a blank line before a comment the other re-wrote. Kept the re-write, killed the stray blank. .qmake.conf Ignore 5.7's change to MODULE_VERSION. src/qml/compiler/qqmltypecompiler.cpp src/qml/compiler/qqmlpropertyvalidator.cpp 5.7 changed code in the former that dev moved to the latter. Reflect 5.7's changes there, adapted to dev's form. src/qml/qml/qqmlobjectcreator.cpp One side added new QVariant types; the other changed how it handled each type of QVariant (without git seeing any conflict); adapted the new stanzas to work the same as the transformed ones. tests/manual/v4/test262 dev had a broken sha1 for it; so used 5.7's 9741ac4655808ac46c127e3d1d8ba3d27ada618e Change-Id: I1fbe2255b97d6ef405cdd1d0cea7fab8dc351d6f
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Edward Welbourne2016-07-151-2/+2
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/quick/demos/photoviewer/deployment.pri One side made it redundant; the other removed part of it; remove it all ! src/quick/scenegraph/util/qsgatlastexture.cpp One side changed a preprocessor condition, the other a code condition, on adjacent lines; keep both changes. tests/auto/qml/debugger/qqmlprofilerservice/tst_qqmlprofilerservice.cpp One side changed a condition, the other the content of its block; keep both. Change-Id: Idb8937f92a7edb28212449dfe0c5cfdb8e6de986
| | * Flickable: fix minXExtent/minYExtent when content is smaller than viewAndrea Bernabei2016-07-011-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At the moment, defining leftMargin (or topMargin) and contentWidth (or contentHeight) so that "leftMargin+contentWidth < flickable.width" (or topMargin+contentHeight < flickable.height) leads to widthRatio (or heightRatio) having value != 1. The value should, however, be 1, as the content is completely visible inside the view, margins included. As a sideeffect, under the assumptions described above, it will now not be possible to scroll the leftMargin (or topMargin) out of screen, something which was possible (and it shouldn't have) before this fix. Task-number: QTBUG-53726 Change-Id: I22426c8038e90a2cfc7445914206eae0e781a3fb Reviewed-by: Robin Burchell <robin.burchell@viroteck.net> Reviewed-by: Albert Astals Cid <albert.astals@canonical.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | QML: Pass the kind of geometry change aroundErik Verbruggen2016-07-111-3/+3
|/ / | | | | | | | | | | | | | | | | | | | | | | | | This prevents re-calculation of what actually changed, and removes the now unused parameter newGeometry. Other than this change calculation, the only place where oldGeometry was used is QQuickListViewPrivate::itemGeometryChanged. To get rid of oldGeometry too, QQuickListViewPrivate now stores the current (i.e. last known) geometry, and updates it in itemGeometryChanged. Change-Id: I8a5286d08a04132c9a4c81de7ce221f5676946e6 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io> Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-06-101-0/+2
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Part of 0e053528 was reverted in the merge, about lastTimestamp. It will be applied later in separate commit. qmltest::shadersource-dynamic-sourceobject::test_endresult() was blacklisted on linux. Conflicts: .qmake.conf tests/auto/qml/debugger/qqmlprofilerservice/tst_qqmlprofilerservice.cpp tests/auto/qmltest/BLACKLIST tests/auto/qmltest/qmltest.pro Task-number: QTBUG-53590 Task-number: QTBUG-53971 Change-Id: I48af90b49a3c7b29de16f4178a04807f8bc05130
| * Flickable: MovementEndingTimerInterval is used only on OS XShawn Rutledge2016-05-251-0/+2
| | | | | | | | | | | | | | After 9b8d0bff, some compilers complain that it's an unused variable. Change-Id: I4a89ce7a7d73cfc039a2e2d1ad48ec7d073cf7cc Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-05-191-4/+4
|\| | | | | | | | | | | | | | | | | Conflicts: src/plugins/qmltooling/qmldbg_profiler/qqmlprofilerservice.cpp src/qml/jsruntime/qv4engine.cpp src/qml/jsruntime/qv4engine_p.h Change-Id: I89ffccd699bee675732758d039e22224b275d60d
| * Flickable: start movementEndingTimer consistently only on OSXShawn Rutledge2016-05-111-4/+4
| | | | | | | | | | | | | | | | | | | | Amends 1929fee8e17e9ca66e7fe08faa9ed9fa7fdbb127 to prevent extra bounce at the ends. Task-number: QTBUG-47697 Task-number: QTBUG-53177 Change-Id: I23e63d8e0555e1503ff028ad2f0767b05ef39432 Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
* | Flickable: add AutoFlickIfNeeded as an option for flickableDirectionShawn Rutledge2016-05-131-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If you want to disable all movement when the user tries to flick or drag, you previously had to set interactive: false. Maybe you need to bind that to some calculation to determine whether the content fits completely inside the Flickable or not. This way is easier. BTW the AutoFlickIfNeeded can be ORed with HorizontalFlick or VerticalFlick, but we don't document it because AutoFlickDirection=0, so it's not useful to OR that with anything. Task-number: QTBUG-31121 Change-Id: Ib03b0f223cb40f0338510c318aa37e70ce71514d Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into 5.7J-P Nurmi2016-03-011-0/+1
|\| | | | | | | | | | | | | Conflicts: src/plugins/qmltooling/qmldbg_native/qmldbg_native.pro Change-Id: I3ca8f0422828191b7e19539c25f31f2d048e9f18
| * Flickable: handle wheel NoScrollPhase the same as ScrollUpdateShawn Rutledge2016-03-011-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before change f253f4c in qtbase, when an ordinary mouse wheel is rotated the phase would be ScrollUpdate continuously, without going through the other phases; whereas on a gesture-interpreting trackpad there would be a ScrollBegin first. Now, an ordinary wheel mouse uses NoScrollPhase continuously, which makes it easier to tell the two cases apart. But we're required to handle the new phase explicitly. To avoid change in existing behavior, we handle it the same as ScrollUpdate phase was handled before. Change-Id: I2d51a89a965704cf843303d523463805b4fe6ff8 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2016-02-121-2/+34
|\| | | | | | | | | | | | | Conflicts: .qmake.conf Change-Id: I356ec83cf687bd2833f9a7c5e820d56b1efa8979
| * Flickable: ensure movementEnded after wheel/trackpad flickShawn Rutledge2016-02-021-2/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In qtdeclarative/tests/manual/touch/flicktext.qml it was already clear that the moving/movingVertically/Horizontally properties did not revert to false after a trackpad flick on OS X. It turns out that the failure to emit the movementEnded signal also caused a scrolling bug in ListView. QQuickFlickable::wheelEvent() looks at event->phase(), but ScrollEnd is not absolute: on OS X with a bluetooth trackpad, it happens once when the user's fingers are lifted, then the "momentum" events occur with ScrollUpdate, and then ScrollEnd happens again at the end of the momentum phase. But if the user's fingers come to rest before being lifted, to stop the momentum, then the ScrollEnd phase happens only once, and that's actually the end of scrolling, flicking and movement, all at once. The events don't seem to provide enough information to disambiguate these two cases; but if ScrollEnd phase occurs, and then we don't receive any more events within some short time interval, we can be pretty sure the scrolling really ended. So, use a timer to check whether any more events have been received, a little later after the ScrollEnd phase. The movementEnded signal can now be emitted for several reasons: the regular timeline ended movement, the velocityTimeline ended movement, or the movementEndingTimer sent an event. Also, when flicking with a physical mouse wheel, flickStarted was emitted multiple times; now it will be emitted only once. Task-number: QTBUG-47151 Change-Id: I534e99befbd9bf6af24c4ebdca73dd21964f1063 Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* | 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>
* Fix ListView.OverlayHeaderJ-P Nurmi2015-12-231-2/+2
| | | | | | | | Infinite loop because of rounding in QQuickFlickablePrivate::fixup(). Change-Id: Icffe216587d90660ac3cb8090a676868416566c8 Task-number: QTBUG-50105 Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* Flickable: avoid perturbing the timeline further while in overshootShawn Rutledge2015-12-071-4/+6
| | | | | | | | | | | | | | | | | | | The bug was that when using the mouse wheel, a single "scroll down" wheel event followed by a rapid succession of "scroll up" events would cause extreme overshoot. Experimentally determined that when this happens, the calls to timeline.accel() in QQuickFlickablePrivate::flick() were occurring after the call to accel in QQuickFlickablePrivate::viewportAxisMoved(). But nearby, data.inOvershoot is set to true, so that can be used to avoid calling accel() additional times in flick(). So basically, this patch avoids doing any more acceleration in response to further wheel events after the momentum from previous events has already taken the content beyond bounds. Task-number: QTBUG-21328 Change-Id: I3ab5510a288a080f6b526407b6a2293c44a2498a Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com> Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* Don't send delayed mouse presses to ancestors of the replaying Flickable.Andrew den Exter2015-10-121-5/+1
| | | | | | | | | | | | | If a Flickable delayed a mouse press event and then replayed it later, ancestor items of that Flickable would receive the press twice: once when filtering events of the Flickable, and again when the event was replayed to a descendent of the Flickable. Extend the protection against a Flickable receiving that repeat event to all ancestor items so this doesn't happen. Change-Id: I438c146130c24a7d47e9e8712a1ab08f3d915a06 Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com> Reviewed-by: Martin Jones <martin.jones@qinetic.com.au>
* Flickable: remove spurious emission of content size changesJ-P Nurmi2015-09-291-6/+2
| | | | | | | | | | | | If contentWidth or contentHeight is negative (unspecified), Flickable should not emit contentWidthChanged() or contentHeightChanged() when its own geometry changes. The value of contentWidth or contentHeight does not change. It remains negative (unspecified). Change-Id: Iad478d11e2e4370d2e94abe84cfd62d144e23dd9 Task-number: QTBUG-35038 Reviewed-by: Robin Burchell <robin.burchell@viroteck.net> Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.5' into 5.6Ulf Hermann2015-08-181-15/+32
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/debugger/qv4debugservice.cpp src/qml/jsruntime/qv4value_inl_p.h src/qml/jsruntime/qv4value_p.h src/qml/memory/qv4mm.cpp src/qml/memory/qv4mm_p.h src/qml/qml/qqmlnotifier_p.h src/qml/qml/qqmlproperty.cpp src/quick/items/qquickflickable.cpp src/quick/items/qquicktextedit.cpp tests/auto/quick/qquickwindow/BLACKLIST The extra changes in qqmlbinding.cpp are ported from changes to qqmlproperty.cpp that occurred in parallel with writeBinding() being moved to qqmlbinding.cpp. Change-Id: I16d1920abf448c29a01822256f52153651a56356
| * Flickable: drag-over-bounds is not velocity-sensitiveShawn Rutledge2015-07-091-15/+32
| | | | | | | | | | | | | | | | | | | | | | The inspiration for velocity sensitivity was to make it feel more like native trackpad flicking on OS X. But on touchscreens it doesn't make as much sense, and it became too difficult to intentionally overshoot in applications that depend on pull-to-refresh functionality. Task-number: QTBUG-46108 Change-Id: I3fea5324aaac1f003ead200e14b0c76bd8c0ece6 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | Emit movement signals for flick().Michael Brasser2015-07-221-3/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make flick() more like a real flick and ensure the movement signals and properties are updated. This allows them to be handled from QML. This also fixes issues with flick() and dynamic delegates. Flickable has several checks of the form: !d->pressed && !d->hData.moving && !d->vData.moving That were processed incorrectly for flick(), as the moving variables were not being updated. [ChangeLog][QtQuick][Flickable] The movement related signals and properties are now updated for flicks started via the flick function. Change-Id: I7e96e2e12a4d0a0ee73ddd6f29d95f19c44667b0 Task-number: QTBUG-34507 Reviewed-by: Martin Jones <martin.jones@qinetic.com.au>
* | QQuickFlickable: Accept pixel wheel events as well as angle wheel events.Robin Burchell2015-06-291-0/+1
| | | | | | | | | | | | | | | | This fixes the case with two overlapping Flickables both handling wheel events (i.e. not preventing propagation). Change-Id: Ie59ffb02c5e9a52055678d662606543a80414c21 Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
* | QQuickFlickable: Send synthetic release event through QCoreApplicationUlf Hermann2015-06-051-1/+1
|/ | | | | | | | | | As we do this with the press event, we have to do the same with the release event. The application tracks the state of mouse buttons and will get confused if an additional press event without symmetric release event shows up. Change-Id: Ia27a96fa5b207ed8aaad913caf7575de112e8606 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Allow Flickable's grab to be stolen if dragging over bounds.Andrew den Exter2015-03-191-1/+15
| | | | | | | | | | This allows a parent item to intercept a drag gesture in one direction when the flickable has reached it's limit in that direction without disabling the drag over bounds for drag gestures in the opposite direction. Change-Id: I6ac60113f150dbb8da42d9b5593325b04be166f5 Reviewed-by: Martin Jones <martin.jones@qinetic.com.au>
* Fix flickable stealing gestures when height >= contentHeight.Andrew den Exter2015-03-111-4/+4
| | | | | | | | | | | | | | | Or width >= contentWidth. If newY is equal to both maxY and minY then the second assignment to rejectY can clobber the first. Changing the second assignment to an |= means rejectY is true if either is true. Secondly maxY became positive when height was greater than contentHeight instead of having a maximum of 0, which ensured rejectY evaluated to false in the case newY <= maxY and the mouse was stolen. Change-Id: I6416d0e23c3ef898887a7b3e3fcdc1dc12853548 Reviewed-by: Martin Jones <martin.jones@qinetic.com.au>
* Cleanup math function includes and usageAllan Sandfeld Jensen2015-02-191-2/+2
| | | | | | | | Use std::math on floats and doubles, and qMath on qreals, and only include the math headers actually needed. Change-Id: I1d511d7b1bac0050eaa947c7baee760b736858bf Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Flickable: use wheel event pixel deltas when availableShawn Rutledge2015-02-161-81/+203
| | | | | | | | | | | | | | | | | | | Flickable can now handle wheel events which come from touchpads, providing pixel deltas instead of angle deltas. It will interpret them as distance to flick, rather than using an average-velocity physics model as it does when handling events from a physical mouse wheel. This enables much finer control and limits the tendency to "zing" way out of bounds accidentally. It is achieved by refactoring the direct-drag code which is needed for mouse dragging and for touchpad gesture dragging (and eventually touchscreen dragging) into a new internal drag() method. [ChangeLog][QtQuick][Flickable] Flickable handles pixel deltas from trackpad gestures as drags, for a more native feel Task-number: QTBUG-22407 Change-Id: Ia613ddb25f46d452603f7cb567b74e80c95a346c Reviewed-by: Morten Johan Sørvig <morten.sorvig@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>
* Introduce Flickable.OvershootBounds behaviorJ-P Nurmi2015-01-211-4/+6
| | | | | | | | | | | | | | | | | | | Related to QTBUG-38515. It is not always desired to allow dragging over bounds even if flicking overshoots. This makes it possible to implement collision effects for flicks, while a drag over bounds would still do nothing. [ChangeLog][QtQuick][Flickable] Introduced Flickable.OvershootBounds behavior that allows content overshooting the boundary when flicked, but does not allow dragging content beyond the boundary of Flickable. [ChangeLog][QtQuick][Important Behavior Changes] Flickable.DragAndOvershootBounds value changed from 2 to 3. This will only affect you if you've worked around enum type checking and have the integer value explicitly in your code. Change-Id: I63c3540ab293a9c7c801d81220f74909d3fa1e17 Reviewed-by: Martin Jones <martin.jones@qinetic.com.au>
* Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-10-291-9/+9
|\ | | | | | | | | | | | | | | | | Conflicts: src/quick/items/qquickaccessibleattached_p.h src/quick/items/qquickwindow.cpp src/quick/scenegraph/qsgthreadedrenderloop.cpp Change-Id: I8bf07487a75f9d1b0d6efa5914dd06875fc9654d
| * Return the content position rounded on the right sideGiulio Camuffo2014-10-091-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QQuickFlickable::contentX/Y() returns the negative of the value stored in the QQuickTimeLineValue used by QQuickFlickable. So we must be careful when using things like qRound, and call it with the negative of the value ine the QQuickTimeLineValue, else code like this would fail: QQuickFlickable *f = ... f->setPixelAligned(true) f->setContentY(-10.5) assert(f->contentY() == qRound(-10.5)) // fail The assert expression indeed turns into -11 == -10, which is false but which is not what the user would expect. Change-Id: Ib92ee2fa613b751462237349d9e4e2f2b4652f82 Reviewed-by: Martin Jones <martin.jones@qinetic.com.au>
* | 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-1/+1
|/ | | | | Change-Id: I2e64950aef710f943c3bc50bc9bf8a1f7fb58d28 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Fix Flickable mouse grab issue.Robert Griebl2014-08-051-0/+1
| | | | | | | | | | | | | This issue cannot be reproduced on the desktop with a mouse (at least I could not). It can however reliably be reproduced on iMX6 embedded hardware with a touch-screen. It seems like the TS driver is reporting mouse events with a much more coarse granularity than the USB mouse driver, which in turn triggers this bug. (Qt4's declarative, as well as Qt5's quick1 and 2 all have the same issue) Change-Id: Id151e3847bc8d77c7b405b9c4d4d5747a6e33ed0 Task-number: QTBUG-27185# Please enter the commit message for your changes. Lines starting Reviewed-by: Martin Jones <martin.jones@jollamobile.com>
* Merge "Merge remote-tracking branch 'origin/5.3' into dev" into refs/staging/devFrederik Gladhorn2014-08-011-21/+20
|\
| * Flickable: Cancel interaction on interactive changesAlbert Astals Cid2014-07-281-21/+20
| | | | | | | | | | | | | | | | | | | | | | Otherwise if you have a listview with a flickable inside with a mouseare inside the pressed is never set to false if you make the interactive property of the outer list depend on the moving of the inner flickable. This makes that when later you change currentIndex of the list and you have StrictlyEnforceRange set, the list won't move because it still thinks it is pressed Change-Id: I2c2021f486fc0a31840c3f2199bc7cb76dc01e3e Reviewed-by: Martin Jones <martin.jones@jollamobile.com>
* | Fix touch/mouse propagation bugsMartin Jones2014-08-011-1/+1
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Filtered mouse release was not delivered if another touch started after a touchMouseId was activated. This meant that any filters expecting a release event would not receive it if another touch was made before release of the touchMouseId. We prevented a touch becoming the touchMouseId in the child mouse filters if there were any existing touches. The normal event delivery, however, does not require a single touch. Further to the previous, a touch could become the touchMouseId, even if the initial press happened when there was an existing touchMouseId. This meant that a touch could turn into a mouse when the existing mouse event was released, resulting in a new touchMouseId which hadn't been through child mouse filters. Flickable delayed press should be sent via normal event processing, as other touch/mouse events are now delivered in this way. We often called childMouseEventFilter() multiple times for each event. This is bad because the gesture handling relies on claiming a gesture in one event, then stealing it in the next. Instead of sending touch to mouse candidate points already determined to be within the item bounds and already transformed, we sent all of the points to the mouse recipient. PinchArea did not store the starting position at the original touch points, so other items could pass the dragThreshold before PinchArea and steal a gesture meant for PinchArea. Task-number: QTBUG-40330 Change-Id: Ic0009c176d3d1cb7cff0b5eda076a2c3ca864136 Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Improve programmatic flicking of ListView (and Flickable).Michael Brasser2014-07-241-1/+5
| | | | | | | | | | Fix bug when programmatically flicking ListView after a real flick in the opposite direction. Also ensure a programmatic flick can flick past bounds when situated at the bounds and DragAndOvershootBounds is set. Task-number: QTBUG-38209 Change-Id: If4a2f65d0e7cb620b9af21f8a25a8a8797976125 Reviewed-by: Martin Jones <martin.jones@jollamobile.com>
* Doc: correct link/compilation errors in Qt DeclarativeNico Vertriest2014-07-021-1/+1
| | | | | | | Task-number: QTBUG-34749 Change-Id: I507d54b0568d77c6099a0bd99f5c369b8667032a Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com> Reviewed-by: Martin Smith <martin.smith@digia.com>
* Fix crash in Flickable with pressDelay.Martin Jones2014-07-021-8/+8
| | | | | | | | Looks like this was exposed by the touch event compression change. Task-number: QTBUG-40000 Change-Id: I037c848e0c5d766857dff3162c244213aba847da Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
* Doc: Fix some code snippet warningsSergio Ahumada2014-04-031-2/+2
| | | | | | | | | | | Seems like \qml \endqml is not able to parse some snippets, so using \code \endcode instead to fix warnings like: Unable to parse QML snippet: "Expected token `{'" at line 1, column 13 Change-Id: Iecf033ff5610405d946390e69c3aa7ec54a21998 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Sze Howe Koh <szehowe.koh@gmail.com>
* Doc: Document signals (not handlers) under \qmlsignalSze Howe Koh2014-03-181-15/+27
| | | | | | | | Append the handler names to the end of the corresponding signal doc. Task-number: QTBUG-35846 Change-Id: I3d627ba7ed5be94e5c402ab092b4d582536499e8 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Use fuzzy comparison for another Flickable StopAtBounds case.Michael Brasser2014-03-071-4/+4
| | | | | | | | | | | | | Be consistent with 268f4615dcf19aad3603833af83ba28eca886aa5, and use fuzzyLessThanOrEqualTo when checking whether we are at or past the bounds when dragging. This prevents a condition where: 1. A Flickable with StopAtBounds is at one of the bounds. 2. A quick flick will sometimes (rarely) cause the Flickable to flick past the bounds. Change-Id: I4165fa133f556fb9d47cc691d11b2ecb77746b33 Reviewed-by: Martin Jones <martin.jones@jollamobile.com>
* Guarantee event's default state as not acceptedArthur Mello2014-02-191-0/+2
| | | | | | | | | | | | Before starting the evaluation of the event to check if it should be accepted or not, set the state of the wheelEvent to not accepted. That way, if the event is not accepted it will be propagated to others elements. Change-Id: I13a71db8e26c888adc03f1bfd3e46480d3b22b6f Task-number: QTBUG-36774 Reviewed-by: Gustavo Pichorim Boiko <gustavo.boiko@canonical.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>