summaryrefslogtreecommitdiff
path: root/src/quick/util
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'master' into animation-refactorwip/animation-refactoranimation-refactorMichael Brasser2012-01-2556-60/+65
|\ | | | | | | | | | | | | Conflicts: tests/auto/declarative/declarative.pro Change-Id: Ie339be2989fac553d351f3077869f1847367b504
| * Update obsolete contact address.Jason McDonald2012-01-2356-56/+56
| | | | | | | | | | | | | | | | 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>
| * QDeclarativeExpression: storing column number in expression locationChristiaan Janssen2012-01-162-4/+9
| | | | | | | | | | Change-Id: I2d69738158abfc76f80b1cfc0e0ccb145fda2245 Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
* | Fix crash when exiting with running animation.Michael Brasser2012-01-242-2/+6
| | | | | | | | | | Change-Id: I3940b3d9f20ca948e435d583366544eecb895fb2 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* | Fix regression in highlight animation.Michael Brasser2012-01-242-5/+15
| | | | | | | | | | Change-Id: Id8476ce3944094d48389f2ef24c0e26635e25c58 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* | Fix SpringAnimation regression.Michael Brasser2012-01-201-52/+63
| | | | | | | | | | | | | | This fixes the tvtennis example. Change-Id: Ia82cb1cdf30a361f8f96db7b7cb090e181d910d9 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Document PathInterpolator.Michael Brasser2012-01-201-0/+42
| | | | | | | | | | Change-Id: I8fb625fb6881af8d0928da3d487dcd659dc384f5 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | PathInterpolator should report angle in clockwise direction.Michael Brasser2012-01-201-0/+5
| | | | | | | | | | | | | | This makes it much more intuitive when binding item rotation to angle. Change-Id: I5654866d9cd1c0ff5899c5571532fc7fedddd440 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Delay deletion of previous transition instance.Michael Brasser2012-01-191-6/+5
| | | | | | | | | | | | | | | | Some animations can change their behavior based on the previous instance. Change-Id: I7fd86a6fab0bca6ff3330126616ed14c4236dac2 Reviewed-by: Bea Lam <bea.lam@nokia.com>
* | Fix potential crash.Michael Brasser2012-01-193-0/+13
| | | | | | | | | | Change-Id: I374d13a80d8778ddad081b29a0cbd63a9bf44f35 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Rename animation backend classes.Michael Brasser2012-01-1915-91/+91
| | | | | | | | | | Change-Id: I8796086097b5464dbe16a92df055e5a153971f21 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Update Transition and TransitionManager for animation changesBea Lam2012-01-174-39/+91
| | | | | | | | | | | | | | | | | | | | | | | | Update QDeclarativeTransition and QDeclarativeTransitionManager to use the new animation classes. QDeclarativeTransition::prepare() now returns a new animation instance each time it is called. Also added isRunning() and finished() for QDeclarativeTransitionManager. Change-Id: I605f13256320ba76f439b859696eac151fb52591 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* | Correctly clear activeAnimations for smoothed, spring, and path animation.Michael Brasser2012-01-173-11/+29
| | | | | | | | | | | | | | Remove animations from the hash when they are deleted. Change-Id: I17dd8f577a6d3cb0282b24d6d52f963caecfcd33 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Test fixes.Michael Brasser2012-01-172-9/+9
| | | | | | | | | | Change-Id: Id656b2f7bae56667de6e5bcb4914f2f65001ef79 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Merge branch 'master' into animation-refactorMichael Brasser2012-01-1656-175/+549
|\ \ | |/ | | | | | | | | | | | | Conflicts: src/quick/util/qdeclarativetimer.cpp tests/auto/qtquick2/qdeclarativeanimations/tst_qdeclarativeanimations.cpp Change-Id: I981b0d01c71035f6611682e742f4330d0ef7891b
| * Reintroduce plugin support for asynchronous hardware specific texturesGunnar Sletta2012-01-131-6/+21
| | | | | | | | | | Change-Id: Iad36542d2137e7a6470009c308ece3de389907c1 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
| * Fix restarting timer from onTriggered handler.Andrew den Exter2012-01-121-1/+1
| | | | | | | | | | | | | | | | | | | | Set the running property to false before calling the triggered handler when a timer finishes so it does not appear to still be running and can be restarted by setting the running property to true. Task-number: QTBUG-22004 Change-Id: I840efa30f5b7ad7d0cda96803d4898be3f390705 Reviewed-by: Martin Jones <martin.jones@nokia.com>
| * Smooth join point for closed Paths starting and ending with PathCurve.Michael Brasser2012-01-061-4/+34
| | | | | | | | | | Change-Id: I6d416e7d794271c10c9eb19de9678b0fe45b083d Reviewed-by: Bea Lam <bea.lam@nokia.com>
| * Update copyright year in license headers.Jason McDonald2012-01-0556-56/+56
| | | | | | | | | | Change-Id: I0a8d99909cac867dce72da70b1bbcb649989a51b Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
| * Document new Path elements.Michael Brasser2012-01-051-6/+263
| | | | | | | | | | Change-Id: Ic1e2aa7da63a7d9e12357a609fc52b3913f14f28 Reviewed-by: Bea Lam <bea.lam@nokia.com>
| * Support <pre> in StyleText textFormatMartin Jones2012-01-051-0/+22
| | | | | | | | | | | | | | Task-number: QTBUG-23159 Change-Id: I842d066efb3a78defba61cc31060840f771f9b11 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
| * Fix moving mixed visible and non-visible View items.Andrew den Exter2012-01-041-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | A removal for a move that included both cached and non-cached was only evaluating the first part of the removal and skipping the remainder. Don't skip all subsequent removals when two ranges are merged, instead reset the current indexes to the start of the merged range and continue on as normal. Task-number: QTBUG-23432 Change-Id: Ieda49e2f68cd0bbbd31ba1e7dfd5af7c3e350d78 Reviewed-by: Bea Lam <bea.lam@nokia.com>
| * Insert items into VisualDataModel.Andrew den Exter2011-12-232-43/+47
| | | | | | | | | | | | | | | | | | | | | | Add API for inserting data directly into a VisualDataModel which can be used among other things to create temporary items that are later resolved to an actual item in the source model. Task-number: QTBUG-21516 Change-Id: I835f0e8d6c5edfb3a21029687de5b700f7400317 Reviewed-by: Martin Jones <martin.jones@nokia.com>
| * Minimize the number of objects created per item in VisualDataModel.Andrew den Exter2011-12-232-21/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Derive from QDeclarativeContext and reference count the context object instead of parenting it to the context. Combined with a weak persistent v8 handle the allows the context object to be returned by javascript accessors instead of creating a new instance for every use. In addition to the efficiency advantages of creating fewer objects, routing all data access through a single object means that object can also persist data instead of just acting as a proxy. Change-Id: I107dc8c901f16f2a4b420ff1cbffa7a6be27de89 Reviewed-by: Martin Jones <martin.jones@nokia.com>
| * Correctly ignore unknown tags in StyledTextMartin Jones2011-12-141-30/+53
| | | | | | | | | | | | | | Also improve tests to compare expected formatting and improve coverage. Change-Id: I021dbdcd147dd7340a0dc1c30f4b104f22efece0 Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
| * Fix crash when items are moved in model.Andrew den Exter2011-12-141-19/+16
| | | | | | | | | | | | | | | | | | | | | | When erasing an item we need to backtrack to the previous item so the next iteration doesn't skip an item. In the worst case the next item is the last and a failure to backtrack will cause the loop to wrap around and run over the list again. Task-number: QTBUG-23107 Change-Id: I82156f6fc1f7973ba11f09a4694230c77c293757 Reviewed-by: Bea Lam <bea.lam@nokia.com>
| * Support <strong> in styled text.Martin Jones2011-12-141-0/+5
| | | | | | | | | | | | | | Task-number: QTBUG-23105 Change-Id: I15968c43fd0797b94584f110c6aeca06eca832b7 Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
* | Prevent PathAnimation from hanging when jumping backwards to beginning.Michael Brasser2012-01-132-2/+11
| | | | | | | | | | | | Task-number: QTBUG-23076 Change-Id: I2aecdfd28f0c3d45b3b805640edaecbd5be2e6fd Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Fix animation looping.Michael Brasser2012-01-134-11/+16
| | | | | | | | | | | | Task-number: QTBUG-23092 Change-Id: I67b4e9565228d4cdf7aa4a8fe1c490a5e471ee47 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Further optimization and cleanup.Michael Brasser2012-01-1314-185/+137
| | | | | | | | | | | | | | | | | | | | | | | | Note that this removes the reference counting, as in practice we seem to always have a single clear owner for each animation. This isn't completely the case for Smoothed, Spring, and Path animations, which also keep previous animations cached, so we will need to specially handle that case. Change-Id: Ie7eb6642ae1ecdee31602cd8d49d1ad703ac102a Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Use the animation timer API for our timer.Michael Brasser2012-01-133-3/+3
| | | | | | | | | | Change-Id: Ifeb7e275770559376f180c98962bc6510ec8cd10 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* | Merge branch 'master' into animation-refactorMichael Brasser2011-12-211-0/+9
|\ \ | |/ | | | | | | | | | | | | | | Conflicts: src/quick/items/qquickcanvas.cpp src/quick/items/qquickcanvas_p.h tools/qmlscene/main.cpp Change-Id: Ia1b0839c5c2bd54d7442292842137cf360a98337
| * Add basic custom easing curve docs and testMartin Jones2011-12-131-0/+9
| | | | | | | | | | Change-Id: Id38434cb71417276635b501d13d0145759de9864 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* | Minor cleanup.Michael Brasser2011-12-211-1/+2
| | | | | | | | | | Change-Id: Id0a3d28cf5fc98b7f0c4a60eef8a8eb4cdaa54ac Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* | Fix SpringAnimation and SmoothedAnimation issuesCharles Yin2011-12-073-8/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the new animation framework, we now create a new parallel animation wrapper group from each call to transition (in smoothedanimation and springanimation), and putting the old qsmoothedanimations/qspringanimations into this new wrapper forces them to stop and then start rather than continue. This will cause problems if the transition() function is called too frequently (for example, called more than twice between 16ms). To fix this issue, introduce a currentDelta() function to QUnifyTimer2 class which can be used for the animations which need to be restarted. Specially for the QSpringAnimation, it can always use the currentDelta() rather than calculating the elapsed time from the last time and the current time. Change-Id: I46ade84165ce1d42e70e048021105ae072734e29 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* | Fix build errors after moving qtquick2 to seperate pluginCharles Yin2011-12-0614-56/+343
| | | | | | | | | | Change-Id: I519b6d5219513eb09c578fd0e904ce92e49cf690 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* | Merge branch 'master' into animation-refactorCharles Yin2011-12-0511-536/+723
|/ | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/declarative/declarative.pro src/declarative/items/qquickanimation_p.h src/declarative/items/qquickcanvas.cpp src/declarative/items/qquickcanvas_p.h src/declarative/particles/qquickparticlesystem.cpp src/declarative/particles/qquickparticlesystem_p.h src/declarative/scenegraph/qsgcontext.cpp src/declarative/scenegraph/qsgcontext_p.h src/declarative/util/qdeclarativeanimation_p.h src/declarative/util/qdeclarativebehavior_p.h src/declarative/util/qdeclarativesmoothedanimation_p.h src/declarative/util/qdeclarativespringanimation_p.h src/declarative/util/qdeclarativetimer_p.h src/declarative/util/util.pri tests/auto/declarative/nodes/nodes.pro tests/auto/declarative/qdeclarativeanimations/tst_qdeclarativeanimations.cpp tests/auto/declarative/qdeclarativebehaviors/tst_qdeclarativebehaviors.cpp tests/auto/declarative/qdeclarativetimer/qdeclarativetimer.pro Change-Id: Ia406128ed943866fc296c7810c3aab94f00e906d
* Say hello to QtQuick moduleKent Hansen2011-12-0257-0/+19927
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>