From cd813f93530512ffcedef6376e8c9266162c8714 Mon Sep 17 00:00:00 2001 From: Martin Jones Date: Thu, 29 Jul 2010 13:55:48 +1000 Subject: Remove use of shared NOTIFY signals Sharing a NOTIFY signal can cause binding loop warnings with no apparent cause. Task-number: QTBUG-12333 Reviewed-by: Aaron Kennedy Reviewed-by: Michael Brasser --- src/declarative/graphicsitems/qdeclarativeitem.cpp | 24 +++++++++---- src/declarative/graphicsitems/qdeclarativeitem_p.h | 19 ++++++---- .../graphicsitems/qdeclarativelistview.cpp | 4 +-- .../graphicsitems/qdeclarativelistview_p.h | 7 ++-- src/declarative/graphicsitems/qdeclarativepath.cpp | 9 +++++ src/declarative/graphicsitems/qdeclarativepath_p.h | 41 +++++++++++++++------- .../graphicsitems/qdeclarativetranslate.cpp | 4 +-- .../graphicsitems/qdeclarativetranslate_p.h | 7 ++-- src/declarative/util/qdeclarativeanimation.cpp | 8 ++--- src/declarative/util/qdeclarativeanimation_p.h | 10 +++--- 10 files changed, 89 insertions(+), 44 deletions(-) diff --git a/src/declarative/graphicsitems/qdeclarativeitem.cpp b/src/declarative/graphicsitems/qdeclarativeitem.cpp index 83f9b20..5221a78 100644 --- a/src/declarative/graphicsitems/qdeclarativeitem.cpp +++ b/src/declarative/graphicsitems/qdeclarativeitem.cpp @@ -511,8 +511,10 @@ QDeclarativeItem *QDeclarativeKeyNavigationAttached::left() const void QDeclarativeKeyNavigationAttached::setLeft(QDeclarativeItem *i) { Q_D(QDeclarativeKeyNavigationAttached); + if (d->left == i) + return; d->left = i; - emit changed(); + emit leftChanged(); } QDeclarativeItem *QDeclarativeKeyNavigationAttached::right() const @@ -524,8 +526,10 @@ QDeclarativeItem *QDeclarativeKeyNavigationAttached::right() const void QDeclarativeKeyNavigationAttached::setRight(QDeclarativeItem *i) { Q_D(QDeclarativeKeyNavigationAttached); + if (d->right == i) + return; d->right = i; - emit changed(); + emit rightChanged(); } QDeclarativeItem *QDeclarativeKeyNavigationAttached::up() const @@ -537,8 +541,10 @@ QDeclarativeItem *QDeclarativeKeyNavigationAttached::up() const void QDeclarativeKeyNavigationAttached::setUp(QDeclarativeItem *i) { Q_D(QDeclarativeKeyNavigationAttached); + if (d->up == i) + return; d->up = i; - emit changed(); + emit upChanged(); } QDeclarativeItem *QDeclarativeKeyNavigationAttached::down() const @@ -550,8 +556,10 @@ QDeclarativeItem *QDeclarativeKeyNavigationAttached::down() const void QDeclarativeKeyNavigationAttached::setDown(QDeclarativeItem *i) { Q_D(QDeclarativeKeyNavigationAttached); + if (d->down == i) + return; d->down = i; - emit changed(); + emit downChanged(); } QDeclarativeItem *QDeclarativeKeyNavigationAttached::tab() const @@ -563,8 +571,10 @@ QDeclarativeItem *QDeclarativeKeyNavigationAttached::tab() const void QDeclarativeKeyNavigationAttached::setTab(QDeclarativeItem *i) { Q_D(QDeclarativeKeyNavigationAttached); + if (d->tab == i) + return; d->tab = i; - emit changed(); + emit tabChanged(); } QDeclarativeItem *QDeclarativeKeyNavigationAttached::backtab() const @@ -576,8 +586,10 @@ QDeclarativeItem *QDeclarativeKeyNavigationAttached::backtab() const void QDeclarativeKeyNavigationAttached::setBacktab(QDeclarativeItem *i) { Q_D(QDeclarativeKeyNavigationAttached); + if (d->backtab == i) + return; d->backtab = i; - emit changed(); + emit backtabChanged(); } /*! diff --git a/src/declarative/graphicsitems/qdeclarativeitem_p.h b/src/declarative/graphicsitems/qdeclarativeitem_p.h index 8c3e084..fffb4f7 100644 --- a/src/declarative/graphicsitems/qdeclarativeitem_p.h +++ b/src/declarative/graphicsitems/qdeclarativeitem_p.h @@ -363,12 +363,12 @@ class QDeclarativeKeyNavigationAttached : public QObject, public QDeclarativeIte Q_OBJECT Q_DECLARE_PRIVATE(QDeclarativeKeyNavigationAttached) - Q_PROPERTY(QDeclarativeItem *left READ left WRITE setLeft NOTIFY changed) - Q_PROPERTY(QDeclarativeItem *right READ right WRITE setRight NOTIFY changed) - Q_PROPERTY(QDeclarativeItem *up READ up WRITE setUp NOTIFY changed) - Q_PROPERTY(QDeclarativeItem *down READ down WRITE setDown NOTIFY changed) - Q_PROPERTY(QDeclarativeItem *tab READ tab WRITE setTab NOTIFY changed) - Q_PROPERTY(QDeclarativeItem *backtab READ backtab WRITE setBacktab NOTIFY changed) + Q_PROPERTY(QDeclarativeItem *left READ left WRITE setLeft NOTIFY leftChanged) + Q_PROPERTY(QDeclarativeItem *right READ right WRITE setRight NOTIFY rightChanged) + Q_PROPERTY(QDeclarativeItem *up READ up WRITE setUp NOTIFY upChanged) + Q_PROPERTY(QDeclarativeItem *down READ down WRITE setDown NOTIFY downChanged) + Q_PROPERTY(QDeclarativeItem *tab READ tab WRITE setTab NOTIFY tabChanged) + Q_PROPERTY(QDeclarativeItem *backtab READ backtab WRITE setBacktab NOTIFY backtabChanged) Q_PROPERTY(Priority priority READ priority WRITE setPriority NOTIFY priorityChanged) Q_ENUMS(Priority) @@ -396,7 +396,12 @@ public: static QDeclarativeKeyNavigationAttached *qmlAttachedProperties(QObject *); Q_SIGNALS: - void changed(); + void leftChanged(); + void rightChanged(); + void upChanged(); + void downChanged(); + void tabChanged(); + void backtabChanged(); void priorityChanged(); private: diff --git a/src/declarative/graphicsitems/qdeclarativelistview.cpp b/src/declarative/graphicsitems/qdeclarativelistview.cpp index 8b616ce..b3e1dc0 100644 --- a/src/declarative/graphicsitems/qdeclarativelistview.cpp +++ b/src/declarative/graphicsitems/qdeclarativelistview.cpp @@ -60,7 +60,7 @@ void QDeclarativeViewSection::setProperty(const QString &property) { if (property != m_property) { m_property = property; - emit changed(); + emit propertyChanged(); } } @@ -68,7 +68,7 @@ void QDeclarativeViewSection::setCriteria(QDeclarativeViewSection::SectionCriter { if (criteria != m_criteria) { m_criteria = criteria; - emit changed(); + emit criteriaChanged(); } } diff --git a/src/declarative/graphicsitems/qdeclarativelistview_p.h b/src/declarative/graphicsitems/qdeclarativelistview_p.h index 9941040..b264861 100644 --- a/src/declarative/graphicsitems/qdeclarativelistview_p.h +++ b/src/declarative/graphicsitems/qdeclarativelistview_p.h @@ -53,8 +53,8 @@ QT_MODULE(Declarative) class Q_AUTOTEST_EXPORT QDeclarativeViewSection : public QObject { Q_OBJECT - Q_PROPERTY(QString property READ property WRITE setProperty NOTIFY changed) - Q_PROPERTY(SectionCriteria criteria READ criteria WRITE setCriteria NOTIFY changed) + Q_PROPERTY(QString property READ property WRITE setProperty NOTIFY propertyChanged) + Q_PROPERTY(SectionCriteria criteria READ criteria WRITE setCriteria NOTIFY criteriaChanged) Q_PROPERTY(QDeclarativeComponent *delegate READ delegate WRITE setDelegate NOTIFY delegateChanged) Q_ENUMS(SectionCriteria) public: @@ -73,7 +73,8 @@ public: QString sectionString(const QString &value); Q_SIGNALS: - void changed(); + void propertyChanged(); + void criteriaChanged(); void delegateChanged(); private: diff --git a/src/declarative/graphicsitems/qdeclarativepath.cpp b/src/declarative/graphicsitems/qdeclarativepath.cpp index 80196a1..c48011d3 100644 --- a/src/declarative/graphicsitems/qdeclarativepath.cpp +++ b/src/declarative/graphicsitems/qdeclarativepath.cpp @@ -474,6 +474,7 @@ void QDeclarativeCurve::setX(qreal x) { if (_x != x) { _x = x; + emit xChanged(); emit changed(); } } @@ -487,6 +488,7 @@ void QDeclarativeCurve::setY(qreal y) { if (_y != y) { _y = y; + emit yChanged(); emit changed(); } } @@ -576,6 +578,7 @@ void QDeclarativePathAttribute::setValue(qreal value) { if (_value != value) { _value = value; + emit valueChanged(); emit changed(); } } @@ -678,6 +681,7 @@ void QDeclarativePathQuad::setControlX(qreal x) { if (_controlX != x) { _controlX = x; + emit controlXChanged(); emit changed(); } } @@ -695,6 +699,7 @@ void QDeclarativePathQuad::setControlY(qreal y) { if (_controlY != y) { _controlY = y; + emit controlYChanged(); emit changed(); } } @@ -761,6 +766,7 @@ void QDeclarativePathCubic::setControl1X(qreal x) { if (_control1X != x) { _control1X = x; + emit control1XChanged(); emit changed(); } } @@ -774,6 +780,7 @@ void QDeclarativePathCubic::setControl1Y(qreal y) { if (_control1Y != y) { _control1Y = y; + emit control1YChanged(); emit changed(); } } @@ -793,6 +800,7 @@ void QDeclarativePathCubic::setControl2X(qreal x) { if (_control2X != x) { _control2X = x; + emit control2XChanged(); emit changed(); } } @@ -806,6 +814,7 @@ void QDeclarativePathCubic::setControl2Y(qreal y) { if (_control2Y != y) { _control2Y = y; + emit control2YChanged(); emit changed(); } } diff --git a/src/declarative/graphicsitems/qdeclarativepath_p.h b/src/declarative/graphicsitems/qdeclarativepath_p.h index 001bcdf..5ab5cfd 100644 --- a/src/declarative/graphicsitems/qdeclarativepath_p.h +++ b/src/declarative/graphicsitems/qdeclarativepath_p.h @@ -68,7 +68,7 @@ class Q_AUTOTEST_EXPORT QDeclarativePathAttribute : public QDeclarativePathEleme Q_OBJECT Q_PROPERTY(QString name READ name WRITE setName NOTIFY nameChanged) - Q_PROPERTY(qreal value READ value WRITE setValue NOTIFY changed) + Q_PROPERTY(qreal value READ value WRITE setValue NOTIFY valueChanged) public: QDeclarativePathAttribute(QObject *parent=0) : QDeclarativePathElement(parent), _value(0) {} @@ -81,6 +81,7 @@ public: Q_SIGNALS: void nameChanged(); + void valueChanged(); private: QString _name; @@ -91,8 +92,8 @@ class Q_AUTOTEST_EXPORT QDeclarativeCurve : public QDeclarativePathElement { Q_OBJECT - Q_PROPERTY(qreal x READ x WRITE setX NOTIFY changed) - Q_PROPERTY(qreal y READ y WRITE setY NOTIFY changed) + Q_PROPERTY(qreal x READ x WRITE setX NOTIFY xChanged) + Q_PROPERTY(qreal y READ y WRITE setY NOTIFY yChanged) public: QDeclarativeCurve(QObject *parent=0) : QDeclarativePathElement(parent), _x(0), _y(0) {} @@ -104,6 +105,10 @@ public: virtual void addToPath(QPainterPath &) {} +Q_SIGNALS: + void xChanged(); + void yChanged(); + private: qreal _x; qreal _y; @@ -122,8 +127,8 @@ class Q_AUTOTEST_EXPORT QDeclarativePathQuad : public QDeclarativeCurve { Q_OBJECT - Q_PROPERTY(qreal controlX READ controlX WRITE setControlX NOTIFY changed) - Q_PROPERTY(qreal controlY READ controlY WRITE setControlY NOTIFY changed) + Q_PROPERTY(qreal controlX READ controlX WRITE setControlX NOTIFY controlXChanged) + Q_PROPERTY(qreal controlY READ controlY WRITE setControlY NOTIFY controlYChanged) public: QDeclarativePathQuad(QObject *parent=0) : QDeclarativeCurve(parent), _controlX(0), _controlY(0) {} @@ -135,6 +140,10 @@ public: void addToPath(QPainterPath &path); +Q_SIGNALS: + void controlXChanged(); + void controlYChanged(); + private: qreal _controlX; qreal _controlY; @@ -144,10 +153,10 @@ class Q_AUTOTEST_EXPORT QDeclarativePathCubic : public QDeclarativeCurve { Q_OBJECT - Q_PROPERTY(qreal control1X READ control1X WRITE setControl1X NOTIFY changed) - Q_PROPERTY(qreal control1Y READ control1Y WRITE setControl1Y NOTIFY changed) - Q_PROPERTY(qreal control2X READ control2X WRITE setControl2X NOTIFY changed) - Q_PROPERTY(qreal control2Y READ control2Y WRITE setControl2Y NOTIFY changed) + Q_PROPERTY(qreal control1X READ control1X WRITE setControl1X NOTIFY control1XChanged) + Q_PROPERTY(qreal control1Y READ control1Y WRITE setControl1Y NOTIFY control1YChanged) + Q_PROPERTY(qreal control2X READ control2X WRITE setControl2X NOTIFY control2XChanged) + Q_PROPERTY(qreal control2Y READ control2Y WRITE setControl2Y NOTIFY control2YChanged) public: QDeclarativePathCubic(QObject *parent=0) : QDeclarativeCurve(parent), _control1X(0), _control1Y(0), _control2X(0), _control2Y(0) {} @@ -165,11 +174,17 @@ public: void addToPath(QPainterPath &path); +Q_SIGNALS: + void control1XChanged(); + void control1YChanged(); + void control2XChanged(); + void control2YChanged(); + private: - int _control1X; - int _control1Y; - int _control2X; - int _control2Y; + qreal _control1X; + qreal _control1Y; + qreal _control2X; + qreal _control2Y; }; class Q_AUTOTEST_EXPORT QDeclarativePathPercent : public QDeclarativePathElement diff --git a/src/declarative/graphicsitems/qdeclarativetranslate.cpp b/src/declarative/graphicsitems/qdeclarativetranslate.cpp index 16a1127..be9b3f3 100644 --- a/src/declarative/graphicsitems/qdeclarativetranslate.cpp +++ b/src/declarative/graphicsitems/qdeclarativetranslate.cpp @@ -90,7 +90,7 @@ void QDeclarativeTranslate::setX(qreal x) return; d->x = x; update(); - emit positionChanged(); + emit xChanged(); } /*! @@ -113,7 +113,7 @@ void QDeclarativeTranslate::setY(qreal y) return; d->y = y; update(); - emit positionChanged(); + emit yChanged(); } /*! diff --git a/src/declarative/graphicsitems/qdeclarativetranslate_p.h b/src/declarative/graphicsitems/qdeclarativetranslate_p.h index 0207dce..b871518 100644 --- a/src/declarative/graphicsitems/qdeclarativetranslate_p.h +++ b/src/declarative/graphicsitems/qdeclarativetranslate_p.h @@ -56,8 +56,8 @@ class Q_AUTOTEST_EXPORT QDeclarativeTranslate : public QGraphicsTransform { Q_OBJECT - Q_PROPERTY(qreal x READ x WRITE setX NOTIFY positionChanged) - Q_PROPERTY(qreal y READ y WRITE setY NOTIFY positionChanged) + Q_PROPERTY(qreal x READ x WRITE setX NOTIFY xChanged) + Q_PROPERTY(qreal y READ y WRITE setY NOTIFY yChanged) public: QDeclarativeTranslate(QObject *parent = 0); @@ -72,7 +72,8 @@ public: void applyTo(QMatrix4x4 *matrix) const; Q_SIGNALS: - void positionChanged(); + void xChanged(); + void yChanged(); private: Q_DECLARE_PRIVATE(QDeclarativeTranslate) diff --git a/src/declarative/util/qdeclarativeanimation.cpp b/src/declarative/util/qdeclarativeanimation.cpp index 9806957..5259e43 100644 --- a/src/declarative/util/qdeclarativeanimation.cpp +++ b/src/declarative/util/qdeclarativeanimation.cpp @@ -939,7 +939,7 @@ void QDeclarativePropertyAction::setTarget(QObject *o) if (d->target == o) return; d->target = o; - emit targetChanged(d->target, d->propertyName); + emit targetChanged(); } QString QDeclarativePropertyAction::property() const @@ -954,7 +954,7 @@ void QDeclarativePropertyAction::setProperty(const QString &n) if (d->propertyName == n) return; d->propertyName = n; - emit targetChanged(d->target, d->propertyName); + emit propertyChanged(); } /*! @@ -2104,7 +2104,7 @@ void QDeclarativePropertyAnimation::setTarget(QObject *o) if (d->target == o) return; d->target = o; - emit targetChanged(d->target, d->propertyName); + emit targetChanged(); } QString QDeclarativePropertyAnimation::property() const @@ -2119,7 +2119,7 @@ void QDeclarativePropertyAnimation::setProperty(const QString &n) if (d->propertyName == n) return; d->propertyName = n; - emit targetChanged(d->target, d->propertyName); + emit propertyChanged(); } QString QDeclarativePropertyAnimation::properties() const diff --git a/src/declarative/util/qdeclarativeanimation_p.h b/src/declarative/util/qdeclarativeanimation_p.h index 59bd465..481c36c 100644 --- a/src/declarative/util/qdeclarativeanimation_p.h +++ b/src/declarative/util/qdeclarativeanimation_p.h @@ -197,7 +197,7 @@ class QDeclarativePropertyAction : public QDeclarativeAbstractAnimation Q_DECLARE_PRIVATE(QDeclarativePropertyAction) Q_PROPERTY(QObject *target READ target WRITE setTarget NOTIFY targetChanged) - Q_PROPERTY(QString property READ property WRITE setProperty NOTIFY targetChanged) + Q_PROPERTY(QString property READ property WRITE setProperty NOTIFY propertyChanged) Q_PROPERTY(QString properties READ properties WRITE setProperties NOTIFY propertiesChanged) Q_PROPERTY(QDeclarativeListProperty targets READ targets) Q_PROPERTY(QDeclarativeListProperty exclude READ exclude) @@ -225,7 +225,8 @@ public: Q_SIGNALS: void valueChanged(const QVariant &); void propertiesChanged(const QString &); - void targetChanged(QObject *, const QString &); + void targetChanged(); + void propertyChanged(); protected: virtual void transition(QDeclarativeStateActions &actions, @@ -246,7 +247,7 @@ class Q_AUTOTEST_EXPORT QDeclarativePropertyAnimation : public QDeclarativeAbstr Q_PROPERTY(QVariant to READ to WRITE setTo NOTIFY toChanged) Q_PROPERTY(QEasingCurve easing READ easing WRITE setEasing NOTIFY easingChanged) Q_PROPERTY(QObject *target READ target WRITE setTarget NOTIFY targetChanged) - Q_PROPERTY(QString property READ property WRITE setProperty NOTIFY targetChanged) + Q_PROPERTY(QString property READ property WRITE setProperty NOTIFY propertyChanged) Q_PROPERTY(QString properties READ properties WRITE setProperties NOTIFY propertiesChanged) Q_PROPERTY(QDeclarativeListProperty targets READ targets) Q_PROPERTY(QDeclarativeListProperty exclude READ exclude) @@ -292,7 +293,8 @@ Q_SIGNALS: void toChanged(QVariant); void easingChanged(const QEasingCurve &); void propertiesChanged(const QString &); - void targetChanged(QObject *, const QString &); + void targetChanged(); + void propertyChanged(); }; class Q_AUTOTEST_EXPORT QDeclarativeColorAnimation : public QDeclarativePropertyAnimation -- cgit v0.12 From 5d5feaa86f3933a1e89b53267953b86e2b0459ed Mon Sep 17 00:00:00 2001 From: Martin Jones Date: Thu, 29 Jul 2010 13:59:59 +1000 Subject: Remove use of shared NOTIFY signals in QGraphicsScale Sharing a NOTIFY signal can cause binding loop warnings with no apparent cause. Task-number: QTBUG-12333 Reviewed-by: Aaron Kennedy Reviewed-by: Michael Brasser --- src/gui/graphicsview/qgraphicstransform.cpp | 3 +++ src/gui/graphicsview/qgraphicstransform.h | 9 ++++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/gui/graphicsview/qgraphicstransform.cpp b/src/gui/graphicsview/qgraphicstransform.cpp index 4ab6975..986bee6 100644 --- a/src/gui/graphicsview/qgraphicstransform.cpp +++ b/src/gui/graphicsview/qgraphicstransform.cpp @@ -267,6 +267,7 @@ void QGraphicsScale::setXScale(qreal scale) return; d->xScale = scale; update(); + emit xScaleChanged(); emit scaleChanged(); } @@ -293,6 +294,7 @@ void QGraphicsScale::setYScale(qreal scale) return; d->yScale = scale; update(); + emit yScaleChanged(); emit scaleChanged(); } @@ -319,6 +321,7 @@ void QGraphicsScale::setZScale(qreal scale) return; d->zScale = scale; update(); + emit zScaleChanged(); emit scaleChanged(); } diff --git a/src/gui/graphicsview/qgraphicstransform.h b/src/gui/graphicsview/qgraphicstransform.h index 58b201a..d8c9654 100644 --- a/src/gui/graphicsview/qgraphicstransform.h +++ b/src/gui/graphicsview/qgraphicstransform.h @@ -85,9 +85,9 @@ class Q_GUI_EXPORT QGraphicsScale : public QGraphicsTransform Q_OBJECT Q_PROPERTY(QVector3D origin READ origin WRITE setOrigin NOTIFY originChanged) - Q_PROPERTY(qreal xScale READ xScale WRITE setXScale NOTIFY scaleChanged) - Q_PROPERTY(qreal yScale READ yScale WRITE setYScale NOTIFY scaleChanged) - Q_PROPERTY(qreal zScale READ zScale WRITE setZScale NOTIFY scaleChanged) + Q_PROPERTY(qreal xScale READ xScale WRITE setXScale NOTIFY xScaleChanged) + Q_PROPERTY(qreal yScale READ yScale WRITE setYScale NOTIFY yScaleChanged) + Q_PROPERTY(qreal zScale READ zScale WRITE setZScale NOTIFY zScaleChanged) public: QGraphicsScale(QObject *parent = 0); ~QGraphicsScale(); @@ -108,6 +108,9 @@ public: Q_SIGNALS: void originChanged(); + void xScaleChanged(); + void yScaleChanged(); + void zScaleChanged(); void scaleChanged(); private: -- cgit v0.12 From d27e7484c8fcb08e0c533b9a8bf5af8d527b1de3 Mon Sep 17 00:00:00 2001 From: Yann Bodson Date: Thu, 29 Jul 2010 15:12:17 +1000 Subject: Document elements that are focus scopes. Task-number: QTBUG-12404 --- src/declarative/graphicsitems/qdeclarativegridview.cpp | 8 +++++--- src/declarative/graphicsitems/qdeclarativelistview.cpp | 10 ++++++---- src/declarative/graphicsitems/qdeclarativeloader.cpp | 3 +++ src/declarative/graphicsitems/qdeclarativepathview.cpp | 5 ++++- 4 files changed, 18 insertions(+), 8 deletions(-) diff --git a/src/declarative/graphicsitems/qdeclarativegridview.cpp b/src/declarative/graphicsitems/qdeclarativegridview.cpp index 89b3958..f02ef6b 100644 --- a/src/declarative/graphicsitems/qdeclarativegridview.cpp +++ b/src/declarative/graphicsitems/qdeclarativegridview.cpp @@ -1085,13 +1085,15 @@ void QDeclarativeGridViewPrivate::flick(AxisData &data, qreal minExtent, qreal m \c portrait data directly. An improved grid view is shown below. The delegate is visually improved and is moved - into a separate \c contactDelegate component. Also, the currently selected item is highlighted - with a blue \l Rectangle using the \l highlight property, and \c focus is set to \c true - to enable keyboard navigation for the grid view. + into a separate \c contactDelegate component. \snippet doc/src/snippets/declarative/gridview/gridview.qml classdocs advanced \image gridview-highlight.png + The currently selected item is highlighted with a blue \l Rectangle using the \l highlight property, + and \c focus is set to \c true to enable keyboard navigation for the grid view. + The grid view itself is a focus scope (see \l{qmlfocus#Acquiring Focus and Focus Scopes}{the focus documentation page} for more details). + Delegates are instantiated as needed and may be destroyed at any time. State should \e never be stored in a delegate. diff --git a/src/declarative/graphicsitems/qdeclarativelistview.cpp b/src/declarative/graphicsitems/qdeclarativelistview.cpp index b3e1dc0..b0a11b9 100644 --- a/src/declarative/graphicsitems/qdeclarativelistview.cpp +++ b/src/declarative/graphicsitems/qdeclarativelistview.cpp @@ -1385,14 +1385,16 @@ void QDeclarativeListViewPrivate::flick(AxisData &data, qreal minExtent, qreal m the delegate is able to access the model's \c name and \c number data directly. An improved list view is shown below. The delegate is visually improved and is moved - into a separate \c contactDelegate component. Also, the currently selected item is highlighted - with a blue \l Rectangle using the \l highlight property, and \c focus is set to \c true - to enable keyboard navigation for the list view. + into a separate \c contactDelegate component. \snippet doc/src/snippets/declarative/listview/listview.qml classdocs advanced \image listview-highlight.png - In a GridView, delegates are instantiated as needed and may be destroyed at any time. + The currently selected item is highlighted with a blue \l Rectangle using the \l highlight property, + and \c focus is set to \c true to enable keyboard navigation for the list view. + The list view itself is a focus scope (see \l{qmlfocus#Acquiring Focus and Focus Scopes}{the focus documentation page} for more details). + + Delegates are instantiated as needed and may be destroyed at any time. State should \e never be stored in a delegate. \note Views do not enable \e clip automatically. If the view diff --git a/src/declarative/graphicsitems/qdeclarativeloader.cpp b/src/declarative/graphicsitems/qdeclarativeloader.cpp index cc7f8e5..d28181e 100644 --- a/src/declarative/graphicsitems/qdeclarativeloader.cpp +++ b/src/declarative/graphicsitems/qdeclarativeloader.cpp @@ -159,6 +159,9 @@ void QDeclarativeLoaderPrivate::initResize() unloads "Page1.qml" and frees resources consumed by it. + Note that Loader is a focus scope. Its \c focus property must be set to \c true for any of its children + to get the \e {active focus} (see \l{qmlfocus#Acquiring Focus and Focus Scopes}{the focus documentation page} for more details). + \sa {dynamic-object-creation}{Dynamic Object Creation} */ diff --git a/src/declarative/graphicsitems/qdeclarativepathview.cpp b/src/declarative/graphicsitems/qdeclarativepathview.cpp index acf9827..3ad8fb38 100644 --- a/src/declarative/graphicsitems/qdeclarativepathview.cpp +++ b/src/declarative/graphicsitems/qdeclarativepathview.cpp @@ -314,7 +314,7 @@ void QDeclarativePathViewPrivate::regenerate() and XmlListModel, or custom model classes defined in C++ that inherit from QAbstractListModel. - A ListView has a \l model, which defines the data to be displayed, and + The view has a \l model, which defines the data to be displayed, and a \l delegate, which defines how the data should be displayed. The \l delegate is instantiated for each item on the \l path. The items may be flicked to move them along the path. @@ -333,6 +333,9 @@ void QDeclarativePathViewPrivate::regenerate() opacity of the items as they rotate. This additional code can be seen in the PathAttribute documentation.) + The \c focus can be set to \c true to enable keyboard navigation. + The path view itself is a focus scope (see \l{qmlfocus#Acquiring Focus and Focus Scopes}{the focus documentation page} for more details). + Delegates are instantiated as needed and may be destroyed at any time. State should \e never be stored in a delegate. -- cgit v0.12 From c2a22048a045f4e3d03b3251bc9af486250657e4 Mon Sep 17 00:00:00 2001 From: Bea Lam Date: Thu, 29 Jul 2010 16:20:54 +1000 Subject: Add missing \l doc commands --- doc/src/declarative/focus.qdoc | 2 +- doc/src/declarative/qdeclarativei18n.qdoc | 2 +- doc/src/declarative/qdeclarativestates.qdoc | 2 +- doc/src/declarative/tutorial.qdoc | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/src/declarative/focus.qdoc b/doc/src/declarative/focus.qdoc index e3ca963..56ea165 100644 --- a/doc/src/declarative/focus.qdoc +++ b/doc/src/declarative/focus.qdoc @@ -266,7 +266,7 @@ When a QML item explicitly relinquishes focus (by setting its does not automatically select another element to receive focus. That is, it is possible for there to be no currently \e {active focus}. -See the {declarative/keyinteraction/focus}{Keyboard Focus example} for a +See the \l{declarative/keyinteraction/focus}{Keyboard Focus example} for a demonstration of moving keyboard focus between multiple areas using FocusScope elements. diff --git a/doc/src/declarative/qdeclarativei18n.qdoc b/doc/src/declarative/qdeclarativei18n.qdoc index b6e6c6e..70a3587 100644 --- a/doc/src/declarative/qdeclarativei18n.qdoc +++ b/doc/src/declarative/qdeclarativei18n.qdoc @@ -80,5 +80,5 @@ qmlviewer -translation hello.qm hello.qml \endcode -You can see a complete example and source code in the {declarative/i18n}{QML Internationalization example}. +You can see a complete example and source code in the \l{declarative/i18n}{QML Internationalization example}. */ diff --git a/doc/src/declarative/qdeclarativestates.qdoc b/doc/src/declarative/qdeclarativestates.qdoc index 6461925..e7607c6 100644 --- a/doc/src/declarative/qdeclarativestates.qdoc +++ b/doc/src/declarative/qdeclarativestates.qdoc @@ -83,6 +83,6 @@ Other things you can do in a state change: \endlist -The {declarative/animation/states}{States and Transitions example} demonstrates how to declare a basic set of states and then apply animated transitions between them. +The \l {declarative/animation/states}{States and Transitions example} demonstrates how to declare a basic set of states and then apply animated transitions between them. */ diff --git a/doc/src/declarative/tutorial.qdoc b/doc/src/declarative/tutorial.qdoc index 7a97eb1..f913d44 100644 --- a/doc/src/declarative/tutorial.qdoc +++ b/doc/src/declarative/tutorial.qdoc @@ -222,5 +222,5 @@ This is equivalent to writing the two transitions separately. The \l ParallelAnimation element makes sure that the two types of animations (number and color) start at the same time. We could also run them one after the other by using \l SequentialAnimation instead. -For more details on states and transitions, see \l {QML States} and the {declarative/animation/states}{states and transitions example}. +For more details on states and transitions, see \l {QML States} and the \l{declarative/animation/states}{states and transitions example}. */ -- cgit v0.12 From 688791b4d39ed4e96c43621e28c6bb3098d3b70c Mon Sep 17 00:00:00 2001 From: Aaron Kennedy Date: Thu, 29 Jul 2010 16:20:48 +1000 Subject: Improve utility of QMLViewer Adds a startup animation for all platforms, and adds support for file associated and drag and drop on Mac OS X QTBUG-12496 --- tools/qml/Info_mac.plist | 31 +++ tools/qml/browser/Browser.qml | 284 ++++++++++++++++++++ tools/qml/browser/browser.qrc | 9 + tools/qml/browser/images/folder.png | Bin 0 -> 1841 bytes tools/qml/browser/images/titlebar.png | Bin 0 -> 1436 bytes tools/qml/browser/images/titlebar.sci | 5 + tools/qml/browser/images/up.png | Bin 0 -> 662 bytes tools/qml/content/Browser.qml | 284 -------------------- tools/qml/content/images/folder.png | Bin 1841 -> 0 bytes tools/qml/content/images/titlebar.png | Bin 1436 -> 0 bytes tools/qml/content/images/titlebar.sci | 5 - tools/qml/content/images/up.png | Bin 662 -> 0 bytes tools/qml/main.cpp | 476 +++++++++++++++++++++------------- tools/qml/qml.pri | 4 +- tools/qml/qmlruntime.cpp | 62 ++++- tools/qml/qmlruntime.h | 1 + tools/qml/qmlruntime.qrc | 9 - tools/qml/startup/Logo.qml | 138 ++++++++++ tools/qml/startup/qt-back.png | Bin 0 -> 3549 bytes tools/qml/startup/qt-blue.jpg | Bin 0 -> 20900 bytes tools/qml/startup/qt-front.png | Bin 0 -> 3318 bytes tools/qml/startup/qt-sketch.jpg | Bin 0 -> 17048 bytes tools/qml/startup/qt-text.png | Bin 0 -> 14565 bytes tools/qml/startup/quick-blur.png | Bin 0 -> 2826 bytes tools/qml/startup/quick-regular.png | Bin 0 -> 1399 bytes tools/qml/startup/shadow.png | Bin 0 -> 1592 bytes tools/qml/startup/startup.qml | 126 +++++++++ tools/qml/startup/startup.qrc | 16 ++ tools/qml/startup/white-star.png | Bin 0 -> 2651 bytes 29 files changed, 968 insertions(+), 482 deletions(-) create mode 100644 tools/qml/browser/Browser.qml create mode 100644 tools/qml/browser/browser.qrc create mode 100644 tools/qml/browser/images/folder.png create mode 100644 tools/qml/browser/images/titlebar.png create mode 100644 tools/qml/browser/images/titlebar.sci create mode 100644 tools/qml/browser/images/up.png delete mode 100644 tools/qml/content/Browser.qml delete mode 100644 tools/qml/content/images/folder.png delete mode 100644 tools/qml/content/images/titlebar.png delete mode 100644 tools/qml/content/images/titlebar.sci delete mode 100644 tools/qml/content/images/up.png delete mode 100644 tools/qml/qmlruntime.qrc create mode 100644 tools/qml/startup/Logo.qml create mode 100644 tools/qml/startup/qt-back.png create mode 100644 tools/qml/startup/qt-blue.jpg create mode 100644 tools/qml/startup/qt-front.png create mode 100644 tools/qml/startup/qt-sketch.jpg create mode 100644 tools/qml/startup/qt-text.png create mode 100644 tools/qml/startup/quick-blur.png create mode 100644 tools/qml/startup/quick-regular.png create mode 100644 tools/qml/startup/shadow.png create mode 100644 tools/qml/startup/startup.qml create mode 100644 tools/qml/startup/startup.qrc create mode 100644 tools/qml/startup/white-star.png diff --git a/tools/qml/Info_mac.plist b/tools/qml/Info_mac.plist index 80ca6a3..0877547 100644 --- a/tools/qml/Info_mac.plist +++ b/tools/qml/Info_mac.plist @@ -14,5 +14,36 @@ @TYPEINFO@ CFBundleExecutable @EXECUTABLE@ + UTExportedTypeDeclarations + + + UTTypeIdentifier + com.nokia.qt.qml + UTTypeDescription + Qt Markup Language + UTTypeConformsTo + + public.plain-text + + UTTypeTagSpecification + + public.filename-extension + + qml + + + + + CFBundleDocumentTypes + + + LSItemContentTypes + + com.nokia.qt.qml + + CFBundleTypeRole + Viewer + + diff --git a/tools/qml/browser/Browser.qml b/tools/qml/browser/Browser.qml new file mode 100644 index 0000000..ff2bb47 --- /dev/null +++ b/tools/qml/browser/Browser.qml @@ -0,0 +1,284 @@ +/**************************************************************************** +** +** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** All rights reserved. +** Contact: Nokia Corporation (qt-info@nokia.com) +** +** This file is part of the QtDeclarative module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the Technology Preview License Agreement accompanying +** this package. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPL included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 2.1 requirements +** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** In addition, as a special exception, Nokia gives you certain additional +** rights. These rights are described in the Nokia Qt LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** If you have questions regarding the use of this file, please contact +** Nokia at qt-info@nokia.com. +** +** +** +** +** +** +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import Qt 4.7 +import Qt.labs.folderlistmodel 1.0 + +Rectangle { + id: root + property bool keyPressed: false + property variant folders: folders1 + property variant view: view1 + width: 320 + height: 480 + color: palette.window + + FolderListModel { + id: folders1 + nameFilters: [ "*.qml" ] + folder: qmlViewerFolder + } + FolderListModel { + id: folders2 + nameFilters: [ "*.qml" ] + folder: qmlViewerFolder + } + + SystemPalette { id: palette } + + function down(path) { + if (folders == folders1) { + view = view2 + folders = folders2; + view1.state = "exitLeft"; + } else { + view = view1 + folders = folders1; + view2.state = "exitLeft"; + } + view.x = root.width; + view.state = "current"; + view.focus = true; + folders.folder = path; + } + function up() { + var path = folders.parentFolder; + if (folders == folders1) { + view = view2 + folders = folders2; + view1.state = "exitRight"; + } else { + view = view1 + folders = folders1; + view2.state = "exitRight"; + } + view.x = -root.width; + view.state = "current"; + view.focus = true; + folders.folder = path; + } + + Component { + id: folderDelegate + Rectangle { + id: wrapper + function launch() { + if (folders.isFolder(index)) { + down(filePath); + } else { + qmlViewer.launch(filePath); + } + } + width: root.width + height: 52 + color: "transparent" + Rectangle { + id: highlight; visible: false + anchors.fill: parent + gradient: Gradient { + GradientStop { id: t1; position: 0.0; color: palette.highlight } + GradientStop { id: t2; position: 1.0; color: Qt.lighter(palette.highlight) } + } + } + Item { + width: 48; height: 48 + Image { source: "images/folder.png"; anchors.centerIn: parent; visible: folders.isFolder(index)} + } + Text { + id: nameText + anchors.fill: parent; verticalAlignment: Text.AlignVCenter + text: fileName + anchors.leftMargin: 54 + font.pixelSize: 32 + color: (wrapper.ListView.isCurrentItem && root.keyPressed) ? palette.highlightedText : palette.windowText + elide: Text.ElideRight + } + MouseArea { + id: mouseRegion + anchors.fill: parent + onClicked: { if (folders == wrapper.ListView.view.model) launch() } + } + states: [ + State { + name: "pressed" + when: mouseRegion.pressed + PropertyChanges { target: highlight; visible: true } + PropertyChanges { target: nameText; color: palette.highlightedText } + } + ] + } + } + + ListView { + id: view1 + anchors.top: titleBar.bottom + anchors.bottom: parent.bottom + x: 0 + width: parent.width + model: folders1 + delegate: folderDelegate + highlight: Rectangle { color: palette.highlight; visible: root.keyPressed && view1.count != 0 } + highlightMoveSpeed: 1000 + pressDelay: 100 + focus: true + state: "current" + states: [ + State { + name: "current" + PropertyChanges { target: view1; x: 0 } + }, + State { + name: "exitLeft" + PropertyChanges { target: view1; x: -root.width } + }, + State { + name: "exitRight" + PropertyChanges { target: view1; x: root.width } + } + ] + transitions: [ + Transition { + to: "current" + SequentialAnimation { + NumberAnimation { properties: "x"; duration: 250 } + } + }, + Transition { + NumberAnimation { properties: "x"; duration: 250 } + NumberAnimation { properties: "x"; duration: 250 } + } + ] + Keys.onPressed: { root.keyPressed = true; } + } + + ListView { + id: view2 + anchors.top: titleBar.bottom + anchors.bottom: parent.bottom + x: parent.width + width: parent.width + model: folders2 + delegate: folderDelegate + highlight: Rectangle { color: palette.highlight; visible: root.keyPressed && view2.count != 0 } + highlightMoveSpeed: 1000 + pressDelay: 100 + states: [ + State { + name: "current" + PropertyChanges { target: view2; x: 0 } + }, + State { + name: "exitLeft" + PropertyChanges { target: view2; x: -root.width } + }, + State { + name: "exitRight" + PropertyChanges { target: view2; x: root.width } + } + ] + transitions: [ + Transition { + to: "current" + SequentialAnimation { + NumberAnimation { properties: "x"; duration: 250 } + } + }, + Transition { + NumberAnimation { properties: "x"; duration: 250 } + } + ] + Keys.onPressed: { root.keyPressed = true; } + } + + Keys.onPressed: { + root.keyPressed = true; + if (event.key == Qt.Key_Return || event.key == Qt.Key_Select || event.key == Qt.Key_Right) { + view.currentItem.launch(); + event.accepted = true; + } else if (event.key == Qt.Key_Left) { + up(); + } + } + + BorderImage { + source: "images/titlebar.sci"; + width: parent.width; + height: 52 + y: -7 + id: titleBar + + Rectangle { + id: upButton + width: 48 + height: titleBar.height - 7 + color: "transparent" + + Image { anchors.centerIn: parent; source: "images/up.png" } + MouseArea { id: upRegion; anchors.centerIn: parent + width: 56 + height: 56 + onClicked: if (folders.parentFolder != "") up() + } + states: [ + State { + name: "pressed" + when: upRegion.pressed + PropertyChanges { target: upButton; color: palette.highlight } + } + ] + } + Rectangle { + color: "gray" + x: 48 + width: 1 + height: 44 + } + + Text { + anchors.left: upButton.right; anchors.right: parent.right; height: parent.height + anchors.leftMargin: 4; anchors.rightMargin: 4 + text: folders.folder + color: "white" + elide: Text.ElideLeft; horizontalAlignment: Text.AlignRight; verticalAlignment: Text.AlignVCenter + font.pixelSize: 32 + } + } +} diff --git a/tools/qml/browser/browser.qrc b/tools/qml/browser/browser.qrc new file mode 100644 index 0000000..9c688e7 --- /dev/null +++ b/tools/qml/browser/browser.qrc @@ -0,0 +1,9 @@ + + + Browser.qml + images/up.png + images/folder.png + images/titlebar.sci + images/titlebar.png + + diff --git a/tools/qml/browser/images/folder.png b/tools/qml/browser/images/folder.png new file mode 100644 index 0000000..e53e2ad Binary files /dev/null and b/tools/qml/browser/images/folder.png differ diff --git a/tools/qml/browser/images/titlebar.png b/tools/qml/browser/images/titlebar.png new file mode 100644 index 0000000..51c9008 Binary files /dev/null and b/tools/qml/browser/images/titlebar.png differ diff --git a/tools/qml/browser/images/titlebar.sci b/tools/qml/browser/images/titlebar.sci new file mode 100644 index 0000000..0418d94 --- /dev/null +++ b/tools/qml/browser/images/titlebar.sci @@ -0,0 +1,5 @@ +border.left: 10 +border.top: 12 +border.bottom: 12 +border.right: 10 +source: titlebar.png diff --git a/tools/qml/browser/images/up.png b/tools/qml/browser/images/up.png new file mode 100644 index 0000000..b05f802 Binary files /dev/null and b/tools/qml/browser/images/up.png differ diff --git a/tools/qml/content/Browser.qml b/tools/qml/content/Browser.qml deleted file mode 100644 index ff2bb47..0000000 --- a/tools/qml/content/Browser.qml +++ /dev/null @@ -1,284 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of the QtDeclarative module of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL$ -** No Commercial Usage -** This file contains pre-release code and may not be distributed. -** You may use this file in accordance with the terms and conditions -** contained in the Technology Preview License Agreement accompanying -** this package. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 2.1 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 2.1 requirements -** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** In addition, as a special exception, Nokia gives you certain additional -** rights. These rights are described in the Nokia Qt LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. -** -** If you have questions regarding the use of this file, please contact -** Nokia at qt-info@nokia.com. -** -** -** -** -** -** -** -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -import Qt 4.7 -import Qt.labs.folderlistmodel 1.0 - -Rectangle { - id: root - property bool keyPressed: false - property variant folders: folders1 - property variant view: view1 - width: 320 - height: 480 - color: palette.window - - FolderListModel { - id: folders1 - nameFilters: [ "*.qml" ] - folder: qmlViewerFolder - } - FolderListModel { - id: folders2 - nameFilters: [ "*.qml" ] - folder: qmlViewerFolder - } - - SystemPalette { id: palette } - - function down(path) { - if (folders == folders1) { - view = view2 - folders = folders2; - view1.state = "exitLeft"; - } else { - view = view1 - folders = folders1; - view2.state = "exitLeft"; - } - view.x = root.width; - view.state = "current"; - view.focus = true; - folders.folder = path; - } - function up() { - var path = folders.parentFolder; - if (folders == folders1) { - view = view2 - folders = folders2; - view1.state = "exitRight"; - } else { - view = view1 - folders = folders1; - view2.state = "exitRight"; - } - view.x = -root.width; - view.state = "current"; - view.focus = true; - folders.folder = path; - } - - Component { - id: folderDelegate - Rectangle { - id: wrapper - function launch() { - if (folders.isFolder(index)) { - down(filePath); - } else { - qmlViewer.launch(filePath); - } - } - width: root.width - height: 52 - color: "transparent" - Rectangle { - id: highlight; visible: false - anchors.fill: parent - gradient: Gradient { - GradientStop { id: t1; position: 0.0; color: palette.highlight } - GradientStop { id: t2; position: 1.0; color: Qt.lighter(palette.highlight) } - } - } - Item { - width: 48; height: 48 - Image { source: "images/folder.png"; anchors.centerIn: parent; visible: folders.isFolder(index)} - } - Text { - id: nameText - anchors.fill: parent; verticalAlignment: Text.AlignVCenter - text: fileName - anchors.leftMargin: 54 - font.pixelSize: 32 - color: (wrapper.ListView.isCurrentItem && root.keyPressed) ? palette.highlightedText : palette.windowText - elide: Text.ElideRight - } - MouseArea { - id: mouseRegion - anchors.fill: parent - onClicked: { if (folders == wrapper.ListView.view.model) launch() } - } - states: [ - State { - name: "pressed" - when: mouseRegion.pressed - PropertyChanges { target: highlight; visible: true } - PropertyChanges { target: nameText; color: palette.highlightedText } - } - ] - } - } - - ListView { - id: view1 - anchors.top: titleBar.bottom - anchors.bottom: parent.bottom - x: 0 - width: parent.width - model: folders1 - delegate: folderDelegate - highlight: Rectangle { color: palette.highlight; visible: root.keyPressed && view1.count != 0 } - highlightMoveSpeed: 1000 - pressDelay: 100 - focus: true - state: "current" - states: [ - State { - name: "current" - PropertyChanges { target: view1; x: 0 } - }, - State { - name: "exitLeft" - PropertyChanges { target: view1; x: -root.width } - }, - State { - name: "exitRight" - PropertyChanges { target: view1; x: root.width } - } - ] - transitions: [ - Transition { - to: "current" - SequentialAnimation { - NumberAnimation { properties: "x"; duration: 250 } - } - }, - Transition { - NumberAnimation { properties: "x"; duration: 250 } - NumberAnimation { properties: "x"; duration: 250 } - } - ] - Keys.onPressed: { root.keyPressed = true; } - } - - ListView { - id: view2 - anchors.top: titleBar.bottom - anchors.bottom: parent.bottom - x: parent.width - width: parent.width - model: folders2 - delegate: folderDelegate - highlight: Rectangle { color: palette.highlight; visible: root.keyPressed && view2.count != 0 } - highlightMoveSpeed: 1000 - pressDelay: 100 - states: [ - State { - name: "current" - PropertyChanges { target: view2; x: 0 } - }, - State { - name: "exitLeft" - PropertyChanges { target: view2; x: -root.width } - }, - State { - name: "exitRight" - PropertyChanges { target: view2; x: root.width } - } - ] - transitions: [ - Transition { - to: "current" - SequentialAnimation { - NumberAnimation { properties: "x"; duration: 250 } - } - }, - Transition { - NumberAnimation { properties: "x"; duration: 250 } - } - ] - Keys.onPressed: { root.keyPressed = true; } - } - - Keys.onPressed: { - root.keyPressed = true; - if (event.key == Qt.Key_Return || event.key == Qt.Key_Select || event.key == Qt.Key_Right) { - view.currentItem.launch(); - event.accepted = true; - } else if (event.key == Qt.Key_Left) { - up(); - } - } - - BorderImage { - source: "images/titlebar.sci"; - width: parent.width; - height: 52 - y: -7 - id: titleBar - - Rectangle { - id: upButton - width: 48 - height: titleBar.height - 7 - color: "transparent" - - Image { anchors.centerIn: parent; source: "images/up.png" } - MouseArea { id: upRegion; anchors.centerIn: parent - width: 56 - height: 56 - onClicked: if (folders.parentFolder != "") up() - } - states: [ - State { - name: "pressed" - when: upRegion.pressed - PropertyChanges { target: upButton; color: palette.highlight } - } - ] - } - Rectangle { - color: "gray" - x: 48 - width: 1 - height: 44 - } - - Text { - anchors.left: upButton.right; anchors.right: parent.right; height: parent.height - anchors.leftMargin: 4; anchors.rightMargin: 4 - text: folders.folder - color: "white" - elide: Text.ElideLeft; horizontalAlignment: Text.AlignRight; verticalAlignment: Text.AlignVCenter - font.pixelSize: 32 - } - } -} diff --git a/tools/qml/content/images/folder.png b/tools/qml/content/images/folder.png deleted file mode 100644 index e53e2ad..0000000 Binary files a/tools/qml/content/images/folder.png and /dev/null differ diff --git a/tools/qml/content/images/titlebar.png b/tools/qml/content/images/titlebar.png deleted file mode 100644 index 51c9008..0000000 Binary files a/tools/qml/content/images/titlebar.png and /dev/null differ diff --git a/tools/qml/content/images/titlebar.sci b/tools/qml/content/images/titlebar.sci deleted file mode 100644 index 0418d94..0000000 --- a/tools/qml/content/images/titlebar.sci +++ /dev/null @@ -1,5 +0,0 @@ -border.left: 10 -border.top: 12 -border.bottom: 12 -border.right: 10 -source: titlebar.png diff --git a/tools/qml/content/images/up.png b/tools/qml/content/images/up.png deleted file mode 100644 index b05f802..0000000 Binary files a/tools/qml/content/images/up.png and /dev/null differ diff --git a/tools/qml/main.cpp b/tools/qml/main.cpp index 4b1162e..7421b5e 100644 --- a/tools/qml/main.cpp +++ b/tools/qml/main.cpp @@ -56,7 +56,8 @@ QT_USE_NAMESPACE QtMsgHandler systemMsgOutput = 0; - +static QDeclarativeViewer *openFile(const QString &fileName); +static void showViewer(QDeclarativeViewer *viewer); #if defined (Q_OS_SYMBIAN) #include @@ -117,6 +118,11 @@ void myMessageOutput(QtMsgType type, const char *msg) #endif +static QDeclarativeViewer* globalViewer = 0; + +// The qml file that is shown if the user didn't specify a QML file +QString initialFile = "qrc:/startup/startup.qml"; + void usage() { qWarning("Usage: qmlviewer [options] "); @@ -175,135 +181,200 @@ void scriptOptsUsage() enum WarningsConfig { ShowWarnings, HideWarnings, DefaultWarnings }; -int main(int argc, char ** argv) +struct ViewerOptions { -#if defined (Q_OS_SYMBIAN) - qInstallMsgHandler(myMessageOutput); -#else - systemMsgOutput = qInstallMsgHandler(myMessageOutput); + ViewerOptions() + : frameless(false), + fps(0.0), + autorecord_from(0), + autorecord_to(0), + dither("none"), + runScript(false), + devkeys(false), + cache(0), + useGL(false), + fullScreen(false), + stayOnTop(false), + maximized(false), + useNativeFileBrowser(true), + experimentalGestures(false), + warningsConfig(DefaultWarnings), + sizeToView(true) + { +#if defined(Q_OS_SYMBIAN) + maximized = true; + useNativeFileBrowser = false; #endif -#if defined (Q_OS_WIN) - // Debugging output is not visible by default on Windows - - // therefore show modal dialog with errors instad. - atexit(showWarnings); +#if defined(Q_WS_MAC) + useGL = true; #endif - -#if defined (Q_WS_X11) || defined (Q_WS_MAC) - //### default to using raster graphics backend for now - bool gsSpecified = false; - for (int i = 0; i < argc; ++i) { - QString arg = argv[i]; - if (arg == "-graphicssystem") { - gsSpecified = true; - break; - } } - if (!gsSpecified) - QApplication::setGraphicsSystem("raster"); -#endif - - QApplication app(argc, argv); - app.setApplicationName("QtQmlViewer"); - app.setOrganizationName("Nokia"); - app.setOrganizationDomain("nokia.com"); - - - - QDeclarativeViewer::registerTypes(); - QDeclarativeTester::registerTypes(); - - bool frameless = false; - QString fileName; - double fps = 0; - int autorecord_from = 0; - int autorecord_to = 0; - QString dither = "none"; + bool frameless; + double fps; + int autorecord_from; + int autorecord_to; + QString dither; QString recordfile; QStringList recordargs; QStringList imports; QStringList plugins; QString script; QString scriptopts; - bool runScript = false; - bool devkeys = false; - int cache = 0; + bool runScript; + bool devkeys; + int cache; QString translationFile; - bool useGL = false; - bool fullScreen = false; - bool stayOnTop = false; - bool maximized = false; - bool useNativeFileBrowser = true; - bool experimentalGestures = false; + bool useGL; + bool fullScreen; + bool stayOnTop; + bool maximized; + bool useNativeFileBrowser; + bool experimentalGestures; - WarningsConfig warningsConfig = DefaultWarnings; - bool sizeToView = true; + WarningsConfig warningsConfig; + bool sizeToView; -#if defined(Q_OS_SYMBIAN) - maximized = true; - useNativeFileBrowser = false; -#endif + QDeclarativeViewer::ScriptOptions scriptOptions; +}; -#if defined(Q_WS_MAC) - useGL = true; -#endif +static ViewerOptions opts; +static QStringList fileNames; - for (int i = 1; i < argc; ++i) { - bool lastArg = (i == argc - 1); - QString arg = argv[i]; +class Application : public QApplication +{ + Q_OBJECT +public: + Application(int &argc, char **&argv) + : QApplication(argc, argv) + {} + +protected: + bool event(QEvent *ev) + { + if (ev->type() != QEvent::FileOpen) + return QApplication::event(ev); + + QFileOpenEvent *fev = static_cast(ev); + + globalViewer->open(fev->file()); + if (!globalViewer->isVisible()) + showViewer(globalViewer); + + return true; + } + +private Q_SLOTS: + void showInitialViewer() + { + QApplication::processEvents(); + + QDeclarativeViewer *viewer = globalViewer; + if (!viewer) + return; + if (viewer->currentFile().isEmpty()) { + if(opts.useNativeFileBrowser) + viewer->open(initialFile); + else + viewer->openFile(); + } + if (!viewer->isVisible()) + showViewer(viewer); + } +}; + +static void parseScriptOptions() +{ + QStringList options = + opts.scriptopts.split(QLatin1Char(','), QString::SkipEmptyParts); + + QDeclarativeViewer::ScriptOptions scriptOptions = 0; + for (int i = 0; i < options.count(); ++i) { + const QString &option = options.at(i); + if (option == QLatin1String("help")) { + scriptOptsUsage(); + } else if (option == QLatin1String("play")) { + scriptOptions |= QDeclarativeViewer::Play; + } else if (option == QLatin1String("record")) { + scriptOptions |= QDeclarativeViewer::Record; + } else if (option == QLatin1String("testimages")) { + scriptOptions |= QDeclarativeViewer::TestImages; + } else if (option == QLatin1String("testerror")) { + scriptOptions |= QDeclarativeViewer::TestErrorProperty; + } else if (option == QLatin1String("exitoncomplete")) { + scriptOptions |= QDeclarativeViewer::ExitOnComplete; + } else if (option == QLatin1String("exitonfailure")) { + scriptOptions |= QDeclarativeViewer::ExitOnFailure; + } else if (option == QLatin1String("saveonexit")) { + scriptOptions |= QDeclarativeViewer::SaveOnExit; + } else if (option == QLatin1String("snapshot")) { + scriptOptions |= QDeclarativeViewer::Snapshot; + } else { + scriptOptsUsage(); + } + } + + opts.scriptOptions = scriptOptions; +} + +static void parseCommandLineOptions(const QStringList &arguments) +{ + for (int i = 1; i < arguments.count(); ++i) { + bool lastArg = (i == arguments.count() - 1); + QString arg = arguments.at(i); if (arg == "-frameless") { - frameless = true; + opts.frameless = true; } else if (arg == "-maximized") { - maximized = true; + opts.maximized = true; } else if (arg == "-fullscreen") { - fullScreen = true; + opts.fullScreen = true; } else if (arg == "-stayontop") { - stayOnTop = true; + opts.stayOnTop = true; } else if (arg == "-netcache") { if (lastArg) usage(); - cache = QString(argv[++i]).toInt(); + opts.cache = arguments.at(++i).toInt(); } else if (arg == "-recordrate") { if (lastArg) usage(); - fps = QString(argv[++i]).toDouble(); + opts.fps = arguments.at(++i).toDouble(); } else if (arg == "-recordfile") { if (lastArg) usage(); - recordfile = QString(argv[++i]); + opts.recordfile = arguments.at(++i); } else if (arg == "-record") { if (lastArg) usage(); - recordargs << QString(argv[++i]); + opts.recordargs << arguments.at(++i); } else if (arg == "-recorddither") { if (lastArg) usage(); - dither = QString(argv[++i]); + opts.dither = arguments.at(++i); } else if (arg == "-autorecord") { if (lastArg) usage(); - QString range = QString(argv[++i]); + QString range = arguments.at(++i); int dash = range.indexOf('-'); if (dash > 0) - autorecord_from = range.left(dash).toInt(); - autorecord_to = range.mid(dash+1).toInt(); + opts.autorecord_from = range.left(dash).toInt(); + opts.autorecord_to = range.mid(dash+1).toInt(); } else if (arg == "-devicekeys") { - devkeys = true; + opts.devkeys = true; } else if (arg == "-dragthreshold") { if (lastArg) usage(); - app.setStartDragDistance(QString(argv[++i]).toInt()); + qApp->setStartDragDistance(arguments.at(++i).toInt()); } else if (arg == QLatin1String("-v") || arg == QLatin1String("-version")) { qWarning("Qt QML Viewer version %s", QT_VERSION_STR); exit(0); } else if (arg == "-translation") { if (lastArg) usage(); - translationFile = argv[++i]; + opts.translationFile = arguments.at(++i); } else if (arg == "-opengl") { - useGL = true; + opts.useGL = true; } else if (arg == "-qmlbrowser") { - useNativeFileBrowser = false; + opts.useNativeFileBrowser = false; } else if (arg == "-warnings") { if (lastArg) usage(); - QString warningsStr = QString(argv[++i]); + QString warningsStr = arguments.at(++i); if (warningsStr == QLatin1String("show")) { - warningsConfig = ShowWarnings; + opts.warningsConfig = ShowWarnings; } else if (warningsStr == QLatin1String("hide")) { - warningsConfig = HideWarnings; + opts.warningsConfig = HideWarnings; } else { usage(); } @@ -316,152 +387,203 @@ int main(int argc, char ** argv) qWarning("Current search path: %s", paths.toLocal8Bit().constData()); exit(0); } - imports << QString(argv[++i]); + opts.imports << arguments.at(++i); } else if (arg == "-P") { if (lastArg) usage(); - plugins << QString(argv[++i]); + opts.plugins << arguments.at(++i); } else if (arg == "-script") { if (lastArg) usage(); - script = QString(argv[++i]); + opts.script = arguments.at(++i); } else if (arg == "-scriptopts") { if (lastArg) usage(); - scriptopts = QString(argv[++i]); + opts.scriptopts = arguments.at(++i); } else if (arg == "-savescript") { if (lastArg) usage(); - script = QString(argv[++i]); - runScript = false; + opts.script = arguments.at(++i); + opts.runScript = false; } else if (arg == "-playscript") { if (lastArg) usage(); - script = QString(argv[++i]); - runScript = true; + opts.script = arguments.at(++i); + opts.runScript = true; } else if (arg == "-sizeviewtorootobject") { - sizeToView = false; + opts.sizeToView = false; } else if (arg == "-sizerootobjecttoview") { - sizeToView = true; + opts.sizeToView = true; } else if (arg == "-experimentalgestures") { - experimentalGestures = true; - } else if (arg[0] != '-') { - fileName = arg; - } else if (1 || arg == "-help") { + opts.experimentalGestures = true; + } else if (!arg.startsWith('-')) { + fileNames.append(arg); + } else if (true || arg == "-help") { usage(); } } - QTranslator qmlTranslator; - if (!translationFile.isEmpty()) { - qmlTranslator.load(translationFile); - app.installTranslator(&qmlTranslator); + if (!opts.scriptopts.isEmpty()) { + + parseScriptOptions(); + + if (opts.script.isEmpty()) + usage(); + + if (!(opts.scriptOptions & QDeclarativeViewer::Record) && !(opts.scriptOptions & QDeclarativeViewer::Play)) + scriptOptsUsage(); + } else if (!opts.script.isEmpty()) { + usage(); } - Qt::WFlags wflags = (frameless ? Qt::FramelessWindowHint : Qt::Widget); - if (stayOnTop) +} + +static QDeclarativeViewer *createViewer() +{ + Qt::WFlags wflags = (opts.frameless ? Qt::FramelessWindowHint : Qt::Widget); + if (opts.stayOnTop) wflags |= Qt::WindowStaysOnTopHint; QDeclarativeViewer *viewer = new QDeclarativeViewer(0, wflags); viewer->setAttribute(Qt::WA_DeleteOnClose, true); - if (!scriptopts.isEmpty()) { - QStringList options = - scriptopts.split(QLatin1Char(','), QString::SkipEmptyParts); - - QDeclarativeViewer::ScriptOptions scriptOptions = 0; - for (int i = 0; i < options.count(); ++i) { - const QString &option = options.at(i); - if (option == QLatin1String("help")) { - scriptOptsUsage(); - } else if (option == QLatin1String("play")) { - scriptOptions |= QDeclarativeViewer::Play; - } else if (option == QLatin1String("record")) { - scriptOptions |= QDeclarativeViewer::Record; - } else if (option == QLatin1String("testimages")) { - scriptOptions |= QDeclarativeViewer::TestImages; - } else if (option == QLatin1String("testerror")) { - scriptOptions |= QDeclarativeViewer::TestErrorProperty; - } else if (option == QLatin1String("exitoncomplete")) { - scriptOptions |= QDeclarativeViewer::ExitOnComplete; - } else if (option == QLatin1String("exitonfailure")) { - scriptOptions |= QDeclarativeViewer::ExitOnFailure; - } else if (option == QLatin1String("saveonexit")) { - scriptOptions |= QDeclarativeViewer::SaveOnExit; - } else if (option == QLatin1String("snapshot")) { - scriptOptions |= QDeclarativeViewer::Snapshot; - } else { - scriptOptsUsage(); - } - } - - if (script.isEmpty()) - usage(); - if (!(scriptOptions & QDeclarativeViewer::Record) && !(scriptOptions & QDeclarativeViewer::Play)) - scriptOptsUsage(); - viewer->setScriptOptions(scriptOptions); - viewer->setScript(script); - } else if (!script.isEmpty()) { - usage(); + if (!opts.scriptopts.isEmpty()) { + viewer->setScriptOptions(opts.scriptOptions); + viewer->setScript(opts.script); } #if !defined(Q_OS_SYMBIAN) logger = viewer->warningsWidget(); - if (warningsConfig == ShowWarnings) { + if (opts.warningsConfig == ShowWarnings) { logger.data()->setDefaultVisibility(LoggerWidget::ShowWarnings); logger.data()->show(); - } else if (warningsConfig == HideWarnings){ + } else if (opts.warningsConfig == HideWarnings){ logger.data()->setDefaultVisibility(LoggerWidget::HideWarnings); } #endif - if (experimentalGestures) + if (opts.experimentalGestures) viewer->enableExperimentalGestures(); - foreach (QString lib, imports) + foreach (QString lib, opts.imports) viewer->addLibraryPath(lib); - foreach (QString plugin, plugins) + foreach (QString plugin, opts.plugins) viewer->addPluginPath(plugin); - viewer->setNetworkCacheSize(cache); - viewer->setRecordFile(recordfile); - viewer->setSizeToView(sizeToView); - if (fps>0) - viewer->setRecordRate(fps); - if (autorecord_to) - viewer->setAutoRecord(autorecord_from,autorecord_to); - if (devkeys) + viewer->setNetworkCacheSize(opts.cache); + viewer->setRecordFile(opts.recordfile); + viewer->setSizeToView(opts.sizeToView); + if (opts.fps > 0) + viewer->setRecordRate(opts.fps); + if (opts.autorecord_to) + viewer->setAutoRecord(opts.autorecord_from, opts.autorecord_to); + if (opts.devkeys) viewer->setDeviceKeys(true); - viewer->setRecordDither(dither); - if (recordargs.count()) - viewer->setRecordArgs(recordargs); + viewer->setRecordDither(opts.dither); + if (opts.recordargs.count()) + viewer->setRecordArgs(opts.recordargs); + + viewer->setUseNativeFileBrowser(opts.useNativeFileBrowser); - viewer->setUseNativeFileBrowser(useNativeFileBrowser); - if (fullScreen && maximized) + return viewer; +} + +void showViewer(QDeclarativeViewer *viewer) +{ + if (opts.fullScreen) + viewer->showFullScreen(); + else if (opts.maximized) + viewer->showMaximized(); + else + viewer->show(); + + viewer->setUseGL(opts.useGL); + viewer->raise(); +} + +QDeclarativeViewer *openFile(const QString &fileName) +{ + QDeclarativeViewer *viewer = globalViewer; + + viewer->open(fileName); + showViewer(viewer); + + return viewer; +} + +int main(int argc, char ** argv) +{ +#if defined (Q_OS_SYMBIAN) + qInstallMsgHandler(myMessageOutput); +#else + systemMsgOutput = qInstallMsgHandler(myMessageOutput); +#endif + +#if defined (Q_OS_WIN) + // Debugging output is not visible by default on Windows - + // therefore show modal dialog with errors instad. + atexit(showWarnings); +#endif + +#if defined (Q_WS_X11) || defined (Q_WS_MAC) + //### default to using raster graphics backend for now + bool gsSpecified = false; + for (int i = 0; i < argc; ++i) { + QString arg = argv[i]; + if (arg == "-graphicssystem") { + gsSpecified = true; + break; + } + } + + if (!gsSpecified) + QApplication::setGraphicsSystem("raster"); +#endif + + Application app(argc, argv); + app.setApplicationName("QtQmlViewer"); + app.setOrganizationName("Nokia"); + app.setOrganizationDomain("nokia.com"); + + QDeclarativeViewer::registerTypes(); + QDeclarativeTester::registerTypes(); + + parseCommandLineOptions(app.arguments()); + + QTranslator qmlTranslator; + if (!opts.translationFile.isEmpty()) { + qmlTranslator.load(opts.translationFile); + app.installTranslator(&qmlTranslator); + } + + if (opts.fullScreen && opts.maximized) qWarning() << "Both -fullscreen and -maximized specified. Using -fullscreen."; - if (fileName.isEmpty()) { + if (fileNames.isEmpty()) { QFile qmlapp(QLatin1String("qmlapp")); if (qmlapp.exists() && qmlapp.open(QFile::ReadOnly)) { - QString content = QString::fromUtf8(qmlapp.readAll()); - qmlapp.close(); - - int newline = content.indexOf(QLatin1Char('\n')); - if (newline >= 0) - fileName = content.left(newline); - else - fileName = content; - } + QString content = QString::fromUtf8(qmlapp.readAll()); + qmlapp.close(); + + int newline = content.indexOf(QLatin1Char('\n')); + if (newline >= 0) + fileNames += content.left(newline); + else + fileNames += content; + } } - if (!fileName.isEmpty()) { - viewer->open(fileName); - fullScreen ? viewer->showFullScreen() : maximized ? viewer->showMaximized() : viewer->show(); + globalViewer = createViewer(); + + if (fileNames.isEmpty()) { + // show the initial viewer delayed. + // This prevents an initial viewer popping up while there + // are FileOpen events coming through the event queue + QTimer::singleShot(1, &app, SLOT(showInitialViewer())); } else { - if (!useNativeFileBrowser) - viewer->openFile(); - fullScreen ? viewer->showFullScreen() : maximized ? viewer->showMaximized() : viewer->show(); - if (useNativeFileBrowser) - viewer->openFile(); + foreach (const QString &fileName, fileNames) + openFile(fileName); } - viewer->setUseGL(useGL); - viewer->raise(); + + QObject::connect(&app, SIGNAL(lastWindowClosed()), &app, SLOT(quit())); return app.exec(); } + +#include "main.moc" diff --git a/tools/qml/qml.pri b/tools/qml/qml.pri index 80afb45..e5b2c7f 100644 --- a/tools/qml/qml.pri +++ b/tools/qml/qml.pri @@ -16,7 +16,9 @@ SOURCES += $$PWD/qmlruntime.cpp \ $$PWD/qdeclarativetester.cpp \ $$PWD/loggerwidget.cpp -RESOURCES = $$PWD/qmlruntime.qrc +RESOURCES = $$PWD/browser/browser.qrc \ + $$PWD/startup/startup.qrc + symbian:!contains(S60_VERSION, 3.1):!contains(S60_VERSION, 3.2) { SOURCES += $$PWD/deviceorientation_symbian.cpp FORMS = $$PWD/recopts.ui \ diff --git a/tools/qml/qmlruntime.cpp b/tools/qml/qmlruntime.cpp index 951b187..08a578c 100644 --- a/tools/qml/qmlruntime.cpp +++ b/tools/qml/qmlruntime.cpp @@ -102,6 +102,49 @@ QT_BEGIN_NAMESPACE +class DragAndDropView : public QDeclarativeView +{ + Q_OBJECT +public: + DragAndDropView(QDeclarativeViewer *parent = 0) + : QDeclarativeView(parent) + { + setAcceptDrops(true); + } + + void dragEnterEvent(QDragEnterEvent *event) + { + const QMimeData *mimeData = event->mimeData(); + if (mimeData->hasUrls()) + event->acceptProposedAction(); + } + + void dragMoveEvent(QDragMoveEvent *event) + { + event->acceptProposedAction(); + } + + void dragLeaveEvent(QDragLeaveEvent *event) + { + event->accept(); + } + + void dropEvent(QDropEvent *event) + { + const QMimeData *mimeData = event->mimeData(); + if (!mimeData->hasUrls()) + return; + const QList urlList = mimeData->urls(); + foreach (const QUrl &url, urlList) { + if (url.scheme() == QLatin1String("file")) { + static_cast(parent())->open(url.toLocalFile()); + event->accept(); + return; + } + } + } +}; + class Runtime : public QObject { Q_OBJECT @@ -596,7 +639,7 @@ QDeclarativeViewer::QDeclarativeViewer(QWidget *parent, Qt::WindowFlags flags) recdlg->warning->hide(); } - canvas = new QDeclarativeView(this); + canvas = new DragAndDropView(this); canvas->setAttribute(Qt::WA_OpaquePaintEvent); canvas->setAttribute(Qt::WA_NoSystemBackground); @@ -605,7 +648,7 @@ QDeclarativeViewer::QDeclarativeViewer(QWidget *parent, Qt::WindowFlags flags) QObject::connect(canvas, SIGNAL(sceneResized(QSize)), this, SLOT(sceneResized(QSize))); QObject::connect(canvas, SIGNAL(statusChanged(QDeclarativeView::Status)), this, SLOT(statusChanged())); - QObject::connect(canvas->engine(), SIGNAL(quit()), QCoreApplication::instance (), SLOT(quit())); + QObject::connect(canvas->engine(), SIGNAL(quit()), this, SLOT(close())); QObject::connect(warningsWidget(), SIGNAL(opened()), this, SLOT(warningsWidgetOpened())); QObject::connect(warningsWidget(), SIGNAL(closed()), this, SLOT(warningsWidgetClosed())); @@ -664,11 +707,11 @@ LoggerWidget *QDeclarativeViewer::warningsWidget() const void QDeclarativeViewer::createMenu() { QAction *openAction = new QAction(tr("&Open..."), this); - openAction->setShortcut(QKeySequence("Ctrl+O")); + openAction->setShortcuts(QKeySequence::Open); connect(openAction, SIGNAL(triggered()), this, SLOT(openFile())); QAction *reloadAction = new QAction(tr("&Reload"), this); - reloadAction->setShortcut(QKeySequence("Ctrl+R")); + reloadAction->setShortcuts(QKeySequence::Refresh); connect(reloadAction, SIGNAL(triggered()), this, SLOT(reload())); QAction *snapshotAction = new QAction(tr("&Take Snapshot"), this); @@ -717,10 +760,16 @@ void QDeclarativeViewer::createMenu() landscapeInvAction->setCheckable(true); QAction *aboutAction = new QAction(tr("&About Qt..."), this); + aboutAction->setMenuRole(QAction::AboutQtRole); connect(aboutAction, SIGNAL(triggered()), qApp, SLOT(aboutQt())); + QAction *closeAction = new QAction(tr("&Close"), this); + closeAction->setShortcuts(QKeySequence::Close); + connect(closeAction, SIGNAL(triggered()), this, SLOT(close())); + QAction *quitAction = new QAction(tr("&Quit"), this); - quitAction->setShortcut(QKeySequence("Ctrl+Q")); + quitAction->setMenuRole(QAction::QuitRole); + quitAction->setShortcuts(QKeySequence::Quit); connect(quitAction, SIGNAL(triggered()), qApp, SLOT(quit())); QMenuBar *menu = menuBar(); @@ -751,6 +800,7 @@ void QDeclarativeViewer::createMenu() fileMenu->addAction(openAction); fileMenu->addAction(reloadAction); fileMenu->addSeparator(); + fileMenu->addAction(closeAction); fileMenu->addAction(quitAction); #if !defined(Q_OS_SYMBIAN) @@ -927,7 +977,7 @@ void QDeclarativeViewer::openFile() { QString cur = canvas->source().toLocalFile(); if (useQmlFileBrowser) { - open("qrc:/content/Browser.qml"); + open("qrc:/browser/Browser.qml"); } else { QString fileName = QFileDialog::getOpenFileName(this, tr("Open QML file"), cur, tr("QML Files (*.qml)")); if (!fileName.isEmpty()) { diff --git a/tools/qml/qmlruntime.h b/tools/qml/qmlruntime.h index 68d3452..7385b14 100644 --- a/tools/qml/qmlruntime.h +++ b/tools/qml/qmlruntime.h @@ -105,6 +105,7 @@ public: QDeclarativeView *view() const; LoggerWidget *warningsWidget() const; + QString currentFile() const { return currentFileOrUrl; } void enableExperimentalGestures(); diff --git a/tools/qml/qmlruntime.qrc b/tools/qml/qmlruntime.qrc deleted file mode 100644 index 3a9e608..0000000 --- a/tools/qml/qmlruntime.qrc +++ /dev/null @@ -1,9 +0,0 @@ - - - content/Browser.qml - content/images/up.png - content/images/folder.png - content/images/titlebar.sci - content/images/titlebar.png - - diff --git a/tools/qml/startup/Logo.qml b/tools/qml/startup/Logo.qml new file mode 100644 index 0000000..9252223 --- /dev/null +++ b/tools/qml/startup/Logo.qml @@ -0,0 +1,138 @@ +import Qt 4.7 + +Rectangle { + id: myApp + width: 411 + height: 411 + color: "transparent" + property alias logoState : myApp.state + signal animationFinished + + Item { + id: sketchBlueHolder + width: sketchLogo.width + height: sketchLogo.height + Image { + id: image1 + x: -44 + y: -45 + smooth: true + source: "shadow.png" + } + Item { + clip: true + width: sketchLogo.width + height: sketchLogo.height + Image { + id: sketchLogo + smooth: true + source: "qt-sketch.jpg" + } + Image { + id: blueLogo + y: -420 + smooth: true + source: "qt-blue.jpg" + } + } + } + + states: [ + State { + name: "showBlueprint" + PropertyChanges { + target: blueLogo + y: 0 + } + PropertyChanges { + target: sketchLogo + opacity: 0 + } + }, + State { + extend: "showBlueprint" + name: "finale" + PropertyChanges { + target: fullLogo + opacity: 1 + } + PropertyChanges { + target: backLogo + opacity: 1 + scale: 1 + } + PropertyChanges { + target: frontLogo + opacity: 1 + scale: 1 + } + PropertyChanges { + target: qtText + opacity: 1 + scale: 1 + } + PropertyChanges { + target: sketchBlueHolder + opacity: 0 + scale: 1.4 + } + } + ] + + transitions: [ + Transition { + to: "showBlueprint" + SequentialAnimation { + NumberAnimation { property: "y"; duration: 600; easing.type: "OutBounce" } + PropertyAction { target: sketchLogo; property: "opacity" } + } + }, + Transition { + to: "finale" + PropertyAction { target: fullLogo; property: "opacity" } + SequentialAnimation { + NumberAnimation { target: backLogo; properties: "scale, opacity"; duration: 300 } + NumberAnimation { target: frontLogo; properties: "scale, opacity"; duration: 300 } + ParallelAnimation { + NumberAnimation { target: qtText; properties: "opacity, scale"; duration: 400; easing.type: "OutQuad" } + NumberAnimation { target: sketchBlueHolder; property: "opacity"; duration: 300; easing.type: "OutQuad" } + NumberAnimation { target: sketchBlueHolder; property: "scale"; duration: 320; easing.type: "OutQuad" } + } + PauseAnimation { duration: 1000 } + ScriptAction { script: myApp.animationFinished() } + } + } + ] + + Item { + id: fullLogo + opacity: 0 + Image { + id: backLogo + x: -16 + y: -41 + opacity: 0 + scale: 0.7 + smooth: true + source: "qt-back.png" + } + Image { + id: frontLogo + x: -17 + y: -41 + opacity: 0 + scale: 1.2 + smooth: true + source: "qt-front.png" + } + Image { + id: qtText + x: -10 + y: -41 + opacity: 0 + scale: 1.2 + smooth: true + source: "qt-text.png" + } + } +} diff --git a/tools/qml/startup/qt-back.png b/tools/qml/startup/qt-back.png new file mode 100644 index 0000000..077215f Binary files /dev/null and b/tools/qml/startup/qt-back.png differ diff --git a/tools/qml/startup/qt-blue.jpg b/tools/qml/startup/qt-blue.jpg new file mode 100644 index 0000000..b204896 Binary files /dev/null and b/tools/qml/startup/qt-blue.jpg differ diff --git a/tools/qml/startup/qt-front.png b/tools/qml/startup/qt-front.png new file mode 100644 index 0000000..dbfb43e Binary files /dev/null and b/tools/qml/startup/qt-front.png differ diff --git a/tools/qml/startup/qt-sketch.jpg b/tools/qml/startup/qt-sketch.jpg new file mode 100644 index 0000000..1ede6f0 Binary files /dev/null and b/tools/qml/startup/qt-sketch.jpg differ diff --git a/tools/qml/startup/qt-text.png b/tools/qml/startup/qt-text.png new file mode 100644 index 0000000..d44995c Binary files /dev/null and b/tools/qml/startup/qt-text.png differ diff --git a/tools/qml/startup/quick-blur.png b/tools/qml/startup/quick-blur.png new file mode 100644 index 0000000..29ec243 Binary files /dev/null and b/tools/qml/startup/quick-blur.png differ diff --git a/tools/qml/startup/quick-regular.png b/tools/qml/startup/quick-regular.png new file mode 100644 index 0000000..38321cb Binary files /dev/null and b/tools/qml/startup/quick-regular.png differ diff --git a/tools/qml/startup/shadow.png b/tools/qml/startup/shadow.png new file mode 100644 index 0000000..44f92fe Binary files /dev/null and b/tools/qml/startup/shadow.png differ diff --git a/tools/qml/startup/startup.qml b/tools/qml/startup/startup.qml new file mode 100644 index 0000000..6792150 --- /dev/null +++ b/tools/qml/startup/startup.qml @@ -0,0 +1,126 @@ +import Qt 4.7 + +Rectangle { + id: treatsApp + width: 800 + height: 480 + color: "darkgrey" + Component.onCompleted: treatsApp.state = "part1" + signal animationFinished + + Logo { + id: logo + x: 165 + y: 35 + rotation: -15 + scale: 0.6 + opacity: 0 + onAnimationFinished: treatsApp.animationFinished(); + } + + states: [ + State { + name: "part1" + PropertyChanges { + target: logo + scale: 0.8 + opacity: 1 + rotation: 0 + } + PropertyChanges { + target: treatsApp + color: "black" + } + PropertyChanges { + target: logo + y: 10 + } + PropertyChanges { + target: quickblur + x: logo.x + 145 + } + PropertyChanges { + target: blurText + opacity: 0 + } + PropertyChanges { + target: quickregular + opacity: 1 + } + PropertyChanges { + target: star + x: -7 + y: -37 + } + } + ] + + + Item { + id: quickblur + x: 800//325 + y: 344 + Image { + id: blurText + source: "quick-blur.png" + } + Image { + id: quickregular + x: -1 + y: 0 + opacity: 0 + source: "quick-regular.png" + } + Image { + id: star + x: -1 + y: 0 + opacity: 0 + source: "white-star.png" + smooth: true + NumberAnimation on rotation { + from: 0 + to: 360 + loops: NumberAnimation.Infinite + running: true + duration: 2000 + } + } + } + + transitions: [ + Transition { + ParallelAnimation { + NumberAnimation { target: logo; property: "opacity"; duration: 500 } + NumberAnimation { target: logo; property: "scale"; duration: 4000; } + NumberAnimation { target: logo; property: "rotation"; duration: 2000; easing.type: "OutBack"} + ColorAnimation { duration: 3000} + SequentialAnimation { + PauseAnimation { duration: 1000 } + ScriptAction { script: logo.logoState = "showBlueprint" } + PauseAnimation { duration: 800 } + ScriptAction { script: logo.logoState = "finale" } + PauseAnimation { duration: 800 } + ParallelAnimation { + NumberAnimation { target: quickblur; property: "x"; duration: 200;} + SequentialAnimation { + PauseAnimation { duration: 200} + ParallelAnimation { + NumberAnimation { target: blurText; property: "opacity"; duration: 300;} + NumberAnimation { target: quickregular; property: "opacity"; duration: 300;} + } + NumberAnimation { target: star; property: "opacity"; from: 0; to: 1; duration: 500 } + PauseAnimation { duration: 200 } + NumberAnimation { target: star; property: "opacity"; from: 1; to: 0; duration: 500 } + } + SequentialAnimation { + PauseAnimation { duration: 150} + NumberAnimation { target: logo; property: "y"; duration: 300; easing.type: "OutBounce" } + } + } + } + } + } + ] + +} // treatsApp diff --git a/tools/qml/startup/startup.qrc b/tools/qml/startup/startup.qrc new file mode 100644 index 0000000..52e6705 --- /dev/null +++ b/tools/qml/startup/startup.qrc @@ -0,0 +1,16 @@ + + + Logo.qml + qt-back.png + qt-blue.jpg + qt-front.png + qt-sketch.jpg + qt-text.png + quick-blur.png + quick-regular.png + shadow.png + startup.qml + startup.qrc + white-star.png + + diff --git a/tools/qml/startup/white-star.png b/tools/qml/startup/white-star.png new file mode 100644 index 0000000..f467c94 Binary files /dev/null and b/tools/qml/startup/white-star.png differ -- cgit v0.12 From eae48b410cc28b83433b7dcba379a31aae2ce2df Mon Sep 17 00:00:00 2001 From: Martin Jones Date: Thu, 29 Jul 2010 16:36:46 +1000 Subject: Add moving and flicking properties to PathView PathView handles its own mouse interaction, but lacked properties similar to those in Flickable to determine when it is stationary. This made it impossible to start an animation when the view stops moving, for example. Task-number: QTBUG-12497 Reviewed-by: Warwick Allison --- .../graphicsitems/qdeclarativepathview.cpp | 108 +- .../graphicsitems/qdeclarativepathview_p.h | 13 + .../graphicsitems/qdeclarativepathview_p_p.h | 13 +- .../qdeclarativepathview/data/test-pathview.0.png | Bin 2321 -> 2412 bytes .../qdeclarativepathview/data/test-pathview.1.png | Bin 2380 -> 2443 bytes .../qdeclarativepathview/data/test-pathview.2.png | Bin 2315 -> 2398 bytes .../qdeclarativepathview/data/test-pathview.3.png | Bin 2372 -> 2390 bytes .../qdeclarativepathview/data/test-pathview.4.png | Bin 2327 -> 2416 bytes .../qdeclarativepathview/data/test-pathview.5.png | Bin 0 -> 2395 bytes .../qdeclarativepathview/data/test-pathview.qml | 1280 +++++++++++++------- .../qdeclarativepathview/test-pathview.qml | 5 + 11 files changed, 939 insertions(+), 480 deletions(-) create mode 100644 tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.5.png diff --git a/src/declarative/graphicsitems/qdeclarativepathview.cpp b/src/declarative/graphicsitems/qdeclarativepathview.cpp index acf9827..002ae21 100644 --- a/src/declarative/graphicsitems/qdeclarativepathview.cpp +++ b/src/declarative/graphicsitems/qdeclarativepathview.cpp @@ -90,6 +90,26 @@ void QDeclarativePathViewAttached::setValue(const QByteArray &name, const QVaria m_metaobject->setValue(name, val); } + +void QDeclarativePathViewPrivate::init() +{ + Q_Q(QDeclarativePathView); + offset = 0; + q->setAcceptedMouseButtons(Qt::LeftButton); + q->setFlag(QGraphicsItem::ItemIsFocusScope); + q->setFiltersChildEvents(true); + q->connect(&tl, SIGNAL(updated()), q, SLOT(ticked())); + lastPosTime.invalidate(); + static int timelineCompletedIdx = -1; + static int movementEndingIdx = -1; + if (timelineCompletedIdx == -1) { + timelineCompletedIdx = QDeclarativeTimeLine::staticMetaObject.indexOfSignal("completed()"); + movementEndingIdx = QDeclarativePathView::staticMetaObject.indexOfSlot("movementEnding()"); + } + QMetaObject::connect(&tl, timelineCompletedIdx, + q, movementEndingIdx, Qt::DirectConnection); +} + QDeclarativeItem *QDeclarativePathViewPrivate::getItem(int modelIndex) { Q_Q(QDeclarativePathView); @@ -848,6 +868,61 @@ void QDeclarativePathView::setInteractive(bool interactive) } /*! + \qmlproperty bool PathView::moving + + This property holds whether the view is currently moving + due to the user either dragging or flicking the view. +*/ +bool QDeclarativePathView::isMoving() const +{ + Q_D(const QDeclarativePathView); + return d->moving; +} + +/*! + \qmlproperty bool PathView::flicking + + This property holds whether the view is currently moving + due to the user flicking the view. +*/ +bool QDeclarativePathView::isFlicking() const +{ + Q_D(const QDeclarativePathView); + return d->flicking; +} + +/*! + \qmlsignal PathView::onMovementStarted() + + This handler is called when the view begins moving due to user + interaction. +*/ + +/*! + \qmlsignal PathView::onMovementEnded() + + This handler is called when the view stops moving due to user + interaction. If a flick was generated, this handler will + be triggered once the flick stops. If a flick was not + generated, the handler will be triggered when the + user stops dragging - i.e. a mouse or touch release. +*/ + +/*! + \qmlsignal PathView::onFlickStarted() + + This handler is called when the view is flicked. A flick + starts from the point that the mouse or touch is released, + while still in motion. +*/ + +/*! + \qmlsignal PathView::onFlickEnded() + + This handler is called when the view stops moving due to a flick. +*/ + +/*! \qmlproperty Component PathView::delegate The delegate provides a template defining each item instantiated by the view. @@ -964,7 +1039,11 @@ void QDeclarativePathView::mousePressEvent(QGraphicsSceneMouseEvent *event) return; } - d->stealMouse = false; + if (d->tl.isActive() && d->flicking) + d->stealMouse = true; // If we've been flicked then steal the click. + else + d->stealMouse = false; + d->lastElapsed = 0; d->lastDist = 0; QDeclarativeItemPrivate::start(d->lastPosTime); @@ -1000,6 +1079,11 @@ void QDeclarativePathView::mouseMoveEvent(QGraphicsSceneMouseEvent *event) d->lastDist = diff; d->startPc = newPc; } + if (!d->moving) { + d->moving = true; + emit movingChanged(); + emit movementStarted(); + } } } @@ -1039,12 +1123,19 @@ void QDeclarativePathView::mouseReleaseEvent(QGraphicsSceneMouseEvent *) d->moveOffset.setValue(d->offset); d->tl.accel(d->moveOffset, velocity, accel, dist); d->tl.callback(QDeclarativeTimeLineCallback(&d->moveOffset, d->fixOffsetCallback, d)); + if (!d->flicking) { + d->flicking = true; + emit flickingChanged(); + emit flickStarted(); + } } else { d->fixOffset(); } d->lastPosTime.invalidate(); ungrabMouse(); + if (!d->tl.isActive()) + movementEnding(); } bool QDeclarativePathView::sendMouseEvent(QGraphicsSceneMouseEvent *event) @@ -1372,6 +1463,21 @@ void QDeclarativePathView::ticked() d->updateCurrent(); } +void QDeclarativePathView::movementEnding() +{ + Q_D(QDeclarativePathView); + if (d->flicking) { + d->flicking = false; + emit flickingChanged(); + emit flickEnded(); + } + if (d->moving && !d->stealMouse) { + d->moving = false; + emit movingChanged(); + emit movementEnded(); + } +} + // find the item closest to the snap position int QDeclarativePathViewPrivate::calcCurrentIndex() { diff --git a/src/declarative/graphicsitems/qdeclarativepathview_p.h b/src/declarative/graphicsitems/qdeclarativepathview_p.h index d2980c6..035a64b 100644 --- a/src/declarative/graphicsitems/qdeclarativepathview_p.h +++ b/src/declarative/graphicsitems/qdeclarativepathview_p.h @@ -74,6 +74,9 @@ class Q_AUTOTEST_EXPORT QDeclarativePathView : public QDeclarativeItem Q_PROPERTY(qreal flickDeceleration READ flickDeceleration WRITE setFlickDeceleration NOTIFY flickDecelerationChanged) Q_PROPERTY(bool interactive READ isInteractive WRITE setInteractive NOTIFY interactiveChanged) + Q_PROPERTY(bool moving READ isMoving NOTIFY movingChanged) + Q_PROPERTY(bool flicking READ isFlicking NOTIFY flickingChanged) + Q_PROPERTY(int count READ count NOTIFY countChanged) Q_PROPERTY(QDeclarativeComponent *delegate READ delegate WRITE setDelegate NOTIFY delegateChanged) Q_PROPERTY(int pathItemCount READ pathItemCount WRITE setPathItemCount NOTIFY pathItemCountChanged) @@ -122,6 +125,9 @@ public: bool isInteractive() const; void setInteractive(bool); + bool isMoving() const; + bool isFlicking() const; + int count() const; QDeclarativeComponent *delegate() const; @@ -151,9 +157,15 @@ Q_SIGNALS: void pathItemCountChanged(); void flickDecelerationChanged(); void interactiveChanged(); + void movingChanged(); + void flickingChanged(); void highlightChanged(); void highlightItemChanged(); void highlightMoveDurationChanged(); + void movementStarted(); + void movementEnded(); + void flickStarted(); + void flickEnded(); protected: void mousePressEvent(QGraphicsSceneMouseEvent *event); @@ -167,6 +179,7 @@ protected: private Q_SLOTS: void refill(); void ticked(); + void movementEnding(); void itemsInserted(int index, int count); void itemsRemoved(int index, int count); void itemsMoved(int,int,int); diff --git a/src/declarative/graphicsitems/qdeclarativepathview_p_p.h b/src/declarative/graphicsitems/qdeclarativepathview_p_p.h index a0d2610..9abec2e 100644 --- a/src/declarative/graphicsitems/qdeclarativepathview_p_p.h +++ b/src/declarative/graphicsitems/qdeclarativepathview_p_p.h @@ -78,6 +78,7 @@ public: , lastElapsed(0), mappedRange(1.0) , stealMouse(false), ownModel(false), interactive(true), haveHighlightRange(true) , autoHighlight(true), highlightUp(false), layoutScheduled(false) + , moving(false), flicking(false) , dragMargin(0), deceleration(100) , moveOffset(this, &QDeclarativePathViewPrivate::setOffset) , firstIndex(-1), pathItems(-1), requestedIndex(-1) @@ -90,15 +91,7 @@ public: { } - void init() { - Q_Q(QDeclarativePathView); - offset = 0; - q->setAcceptedMouseButtons(Qt::LeftButton); - q->setFlag(QGraphicsItem::ItemIsFocusScope); - q->setFiltersChildEvents(true); - q->connect(&tl, SIGNAL(updated()), q, SLOT(ticked())); - lastPosTime.invalidate(); - } + void init(); void itemGeometryChanged(QDeclarativeItem *item, const QRectF &newGeometry, const QRectF &oldGeometry) { if ((newGeometry.size() != oldGeometry.size()) @@ -155,6 +148,8 @@ public: bool autoHighlight : 1; bool highlightUp : 1; bool layoutScheduled : 1; + bool moving : 1; + bool flicking : 1; QElapsedTimer lastPosTime; QPointF lastPos; qreal dragMargin; diff --git a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.0.png b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.0.png index 442ba9f..16a7e10 100644 Binary files a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.0.png and b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.0.png differ diff --git a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.1.png b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.1.png index a9ff20f..116ce88 100644 Binary files a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.1.png and b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.1.png differ diff --git a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.2.png b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.2.png index 157bb99..13896d4 100644 Binary files a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.2.png and b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.2.png differ diff --git a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.3.png b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.3.png index 8c49acb..5d18003 100644 Binary files a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.3.png and b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.3.png differ diff --git a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.4.png b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.4.png index eb2bf54..cd3387f 100644 Binary files a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.4.png and b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.4.png differ diff --git a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.5.png b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.5.png new file mode 100644 index 0000000..9f31c69 Binary files /dev/null and b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.5.png differ diff --git a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.qml b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.qml index 9595a5c..06d32b6 100644 --- a/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.qml +++ b/tests/auto/declarative/qmlvisual/qdeclarativepathview/data/test-pathview.qml @@ -6,409 +6,437 @@ VisualTest { } Frame { msec: 16 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 32 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 48 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 64 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 80 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 96 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 112 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 128 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 144 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 160 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 176 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 192 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 208 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 224 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 240 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 256 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 272 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 288 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 304 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 320 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 336 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 352 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 368 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 384 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 400 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 416 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 432 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 448 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 464 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 480 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 496 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 512 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 528 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 544 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 560 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 576 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 592 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 608 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 624 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 640 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 656 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 672 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 688 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 704 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 720 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 736 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 752 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 768 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 784 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 800 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 816 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 832 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 848 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 864 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 880 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" } Frame { msec: 896 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "01b9c877f51b878ed262943aedcf89b4" + } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 623; y: 222 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 621; y: 222 + modifiers: 0 + sendToViewport: true } Frame { msec: 912 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "1c2d4a99e7e2f5e945c05857d6a463a2" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 609; y: 230 + modifiers: 0 + sendToViewport: true } Frame { msec: 928 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "d69c0678ce2025a8921b089311d219ea" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 583; y: 248 + modifiers: 0 + sendToViewport: true } Frame { msec: 944 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "55a852b268151d660e4945da88b04022" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 559; y: 258 + modifiers: 0 + sendToViewport: true } Frame { msec: 960 image: "test-pathview.0.png" } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 547; y: 264 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 3 + button: 1 + buttons: 0 + x: 547; y: 264 + modifiers: 0 + sendToViewport: true + } Frame { msec: 976 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "55ab61911405e762b39b38d1371ef845" } Frame { msec: 992 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "be3de45165f2f0916f734fecf3f48c47" } Frame { msec: 1008 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "0a523daec6b591a2b5030c6c0b95cb24" } Frame { msec: 1024 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "22da168e523fa385cce1f2e6a05e1332" } Frame { msec: 1040 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "464cb37780cf126df6dad4169445c7bc" } Frame { msec: 1056 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "666b06a0fbe2d10fbf3e15883a166c60" } Frame { msec: 1072 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "223732cd526e09155ca99c80780bc3fa" } Frame { msec: 1088 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "c74cc48188b05c5426a6b955ed9f09a3" } Frame { msec: 1104 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "8d09a95ab09f87277fcc727e9c5da0fb" } Frame { msec: 1120 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "71b7d4ec45270158ba4ca96817d8f231" } Frame { msec: 1136 - hash: "89bb697bb7b7fab38d3ff56e23e43959" - } - Mouse { - type: 2 - button: 1 - buttons: 1 - x: 734; y: 177 - modifiers: 0 - sendToViewport: true + hash: "4847a1e7d792ed58e3476112b02c6fab" } Frame { msec: 1152 - hash: "89bb697bb7b7fab38d3ff56e23e43959" + hash: "ef444a3a960bdc176e004b949e5c89ce" } Frame { msec: 1168 - hash: "89bb697bb7b7fab38d3ff56e23e43959" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 732; y: 177 - modifiers: 0 - sendToViewport: true + hash: "1ebf4badb7f4ef3938868a74740fcbce" } Frame { msec: 1184 - hash: "89bb697bb7b7fab38d3ff56e23e43959" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 726; y: 179 - modifiers: 0 - sendToViewport: true + hash: "022918cd4b54750b0ad28bcb00108f51" } Frame { msec: 1200 - hash: "89bb697bb7b7fab38d3ff56e23e43959" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 716; y: 183 - modifiers: 0 - sendToViewport: true + hash: "1ea398b2b7c52b35981c98b60d5d7a02" } Frame { msec: 1216 - hash: "42c141399fda1cbb2ae117788d87092a" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 700; y: 190 - modifiers: 0 - sendToViewport: true + hash: "05d7619ed0154fa414686522a7ca86c4" } Frame { msec: 1232 - hash: "4d44343eb91838e3eb73e2e5326b5ac2" + hash: "03274e26ea57d1264f21d306533476ef" } Frame { msec: 1248 - hash: "4d44343eb91838e3eb73e2e5326b5ac2" + hash: "5109372d6c62225aaf971aa53c708bee" + } + Frame { + msec: 1264 + hash: "71f10446437963eccb87dd40c172118f" + } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 708; y: 240 + modifiers: 0 + sendToViewport: true } Mouse { type: 5 button: 0 buttons: 1 - x: 677; y: 200 + x: 707; y: 240 modifiers: 0 sendToViewport: true } Frame { - msec: 1264 - hash: "15aaccb4f7961a4e3e6fe57260779d00" + msec: 1280 + hash: "e47426491548162622f9a281c3d062ec" } Mouse { type: 5 button: 0 buttons: 1 - x: 651; y: 209 + x: 685; y: 252 modifiers: 0 sendToViewport: true } Frame { - msec: 1280 - hash: "5628fa3ac9893f5c9690013aad4b881a" + msec: 1296 + hash: "e889fba64d9f94fe18c3750dd6ad9d00" } Mouse { type: 5 button: 0 buttons: 1 - x: 619; y: 219 + x: 635; y: 264 modifiers: 0 sendToViewport: true } Frame { - msec: 1296 - hash: "384db58b6de773ac39ae81e6af4d547d" + msec: 1312 + hash: "7fe200757a6bf752906d195fe341be14" } Mouse { type: 5 button: 0 buttons: 1 - x: 579; y: 229 + x: 569; y: 280 modifiers: 0 sendToViewport: true } Frame { - msec: 1312 - hash: "2a15a27a138b9d3d646b827d026e8843" + msec: 1328 + hash: "aa1f4147dc3fd66f6d9e2605d0759951" } Mouse { type: 5 button: 0 buttons: 1 - x: 535; y: 237 + x: 533; y: 294 modifiers: 0 sendToViewport: true } @@ -416,157 +444,193 @@ VisualTest { type: 3 button: 1 buttons: 0 - x: 535; y: 237 + x: 533; y: 294 modifiers: 0 sendToViewport: true } Frame { - msec: 1328 - hash: "098176f48a148eb2bc5ef67c307baa1c" - } - Frame { msec: 1344 - hash: "f838ab4301bf9d3106cec529f855cecd" + hash: "2b7163ea45860cf81f208c2b68c418b5" } Frame { msec: 1360 - hash: "9725322067a04f83717b059d4970d610" + hash: "a89bd1204fb17d9d8ce7b7f4279e9b1f" } Frame { msec: 1376 - hash: "3605cfbebc3a9eb4460efb2d4b9b6da2" + hash: "683e52637fd5d96ded35f5ade9679822" } Frame { msec: 1392 - hash: "4503a368d8db25d112503dbc3934541d" + hash: "2aa16f06e8bed201746558b1003f7d63" } Frame { msec: 1408 - hash: "80894cc06c82264bf527398ea235da12" + hash: "f2e40e75ddb8004917ae5b8cf144a322" } Frame { msec: 1424 - hash: "d4f9b90f886fc667309b33c9a296410c" + hash: "0f7f64373b065a454c02c32c52a5ef79" } Frame { msec: 1440 - hash: "889d01025cff679b61bff182a1ac9cbc" + hash: "fb4fbd2b3696bfb6135797b1f0158b5c" } Frame { msec: 1456 - hash: "6147bc4455e7cb5ae55cd47be8dc4ad6" + hash: "7a8eafad65ff191a97dcf910393ba4e4" } Frame { msec: 1472 - hash: "ddd10a294eb6b19698c4e9fe4f1508fe" + hash: "3362deae62ba96853d85827f21cec589" } Frame { msec: 1488 - hash: "748e8d9c1971f6258acee5133b7f114b" + hash: "0653838fa3fb5b32e561adc20becc9d2" } Frame { msec: 1504 - hash: "1ef3f32ec9ef950588266bacbe3554a0" + hash: "482e78e6b54cabe007f7e7f4f27a07ee" } Frame { msec: 1520 - hash: "57853ff47b65aba9e76f90b2efec4f8f" + hash: "b51f60864896808c6e41d8a0a990676d" } Frame { msec: 1536 - hash: "3985fea21d89d223c1461d5e96364c76" + hash: "d77e59d69b7c21c82bce9a25d548358c" } Frame { msec: 1552 - hash: "cb5f6a3caeeaed12e91efe43867f2c1f" + hash: "b3dddbb1eee0e2f222434511073c4620" } Frame { msec: 1568 - hash: "cdd4176776d5969373e0fc9a117e3c87" + hash: "d5e0d191582291b269b9e93241d9ac03" + } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 637; y: 218 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 621; y: 240 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 613; y: 248 + modifiers: 0 + sendToViewport: true } Frame { msec: 1584 - hash: "3bac2e7506472db2ae11734240f1c3f4" + hash: "8c12000da88abb70cbc370d2a2ca21d7" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 551; y: 288 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 3 + button: 1 + buttons: 0 + x: 551; y: 288 + modifiers: 0 + sendToViewport: true } Frame { msec: 1600 - hash: "bb572659d79ebda7134c039e40cf2633" + hash: "2854533fd50f5ebb8fc43cf0041883e4" } Frame { msec: 1616 - hash: "e610181bfa17a85281f9c7417088f04f" + hash: "0b3782e842a6c54585d6a266314025d8" } Frame { msec: 1632 - hash: "eb23ff021909589b6d8ce47ebff2c3ed" + hash: "02409885b82ebac931df18d8e23238d7" } Frame { msec: 1648 - hash: "c321dda3878c4b97cc63246c47368224" + hash: "edcbd91ad267c125c431367be3e4a8a3" } Frame { msec: 1664 - hash: "6a65cdfd50e1455356040d4cbc09905e" + hash: "47641fd7ec919b3c041c5acc04b0d083" } Frame { msec: 1680 - hash: "f2a44b12e4e5bae8283c4d227949e4e8" + hash: "ea8f026fee0fba2c27a8df1e1e531acb" } Frame { msec: 1696 - hash: "55418d661f3257b5b79a7dbb172b5b70" + hash: "e2e8a398760be380f9b2b7dbcb03c0e8" } Frame { msec: 1712 - hash: "483d7111c86951918746d6ebe0dd9655" + hash: "a1767f2e10f9ab87050ef246a4a29bbb" } Frame { msec: 1728 - hash: "85c83ac3a294a9320bb04a6721ecf7d5" + hash: "f60cccf793bd6d356d69b1394638a201" } Frame { msec: 1744 - hash: "0d658b897b8e03397ddd8ffe475c2fc0" + hash: "31dc8c50a99164c19445a089223c8813" } Frame { msec: 1760 - hash: "6ed9d7ea344b3c1b1d9196ee36b2f89a" + hash: "78ff726b7da5ba03fa74f66b39bf1006" } Frame { msec: 1776 - hash: "6a1e7f6c03769c2c88e6343fb6c1a2a4" + hash: "6f8a540dccf7182f6aed8903a0afb109" } Frame { msec: 1792 - hash: "9dc51f46e072eac4494d7318f2ecb39b" + hash: "c914c500507b9c7180dcf25e985135e9" } Frame { msec: 1808 - hash: "59e833981c3fcd8a71f4a16d1c454b3a" + hash: "39702ce38bcfca46ef3a8dbb7299c725" } Frame { msec: 1824 - hash: "29b953efdda00548d8cf6fb49fa60d13" + hash: "969b71ee88a1d244e62af1cecc105234" } Frame { msec: 1840 - hash: "fd4611f703f94ebefcc64781993ca85c" + hash: "11c8397fb9d7b993761b08ba8c9958e5" } Frame { msec: 1856 - hash: "aa4789ede618963157b40f099ce84987" + hash: "79ad4a90ab449e3232db993b30786d89" } Frame { msec: 1872 - hash: "8a326b46ec536a67626ee2d2bc06aa9f" + hash: "daf979fd50e0860bf30f377a059d89dc" } Frame { msec: 1888 - hash: "011ff557672d47591e4f0f5c5ee418f1" + hash: "5412e7524dc22e8064c8a8c684092802" } Frame { msec: 1904 - hash: "d72fba857bdc128ddcb5971b86aadcb2" + hash: "2c3bea8bf10ecf6c19b93e94cb7ac0ea" } Frame { msec: 1920 @@ -574,807 +638,919 @@ VisualTest { } Frame { msec: 1936 - hash: "49182b7ae9ef5fb4b9234969abd05960" + hash: "bbfa2f8aaab0abaff9d771d5ec546d96" } Frame { msec: 1952 - hash: "53de60f682574b7a9e6ffaee175fc9ff" + hash: "be2811bf369bc9dd8c5d9deec3b84788" } Frame { msec: 1968 - hash: "2de74fe5b8848c5c781b796146871f45" + hash: "779838915f48eb917d36c3f2b65eedae" + } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 595; y: 236 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 565; y: 256 + modifiers: 0 + sendToViewport: true } Frame { msec: 1984 - hash: "33c87146d8c24dd9c2271d16a8ff5b53" + hash: "d20b5fe14b47dfb1e73f8ef44802da11" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 507; y: 286 + modifiers: 0 + sendToViewport: true } Frame { msec: 2000 - hash: "fdb29214e20d744d9776907061f50358" + hash: "5312dd1f9d309ab5134b8bb67685488e" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 461; y: 288 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 3 + button: 1 + buttons: 0 + x: 461; y: 288 + modifiers: 0 + sendToViewport: true } Frame { msec: 2016 - hash: "8c7c920416c9b775e790e6da24c32927" + hash: "8d6b6cbb74cc654bc5aff10a807dd3cb" } Frame { msec: 2032 - hash: "86b456059e4701379447fffaf9e072f0" + hash: "dee717869177d1de4a26599b120f1c3d" } Frame { msec: 2048 - hash: "f92cc485ee03ef5bce3c4cdc35e00318" + hash: "2b2c60f42024784ceed5c68505dfa5ca" } Frame { msec: 2064 - hash: "2fad58883cb20273cfd79ebca345a66d" + hash: "1a6a108fd6cf607ec08dbedd804d12f7" } Frame { msec: 2080 - hash: "84505ebbc6e12817f11f64aa6f61a0bf" + hash: "10bc4d0a1dc400fedc9a68b68c6525fd" } Frame { msec: 2096 - hash: "ded83cacb89838cc0f3ba14bcc69b66b" + hash: "dc6a4abfbfb38e90af2308320d0f795b" } Frame { msec: 2112 - hash: "5bb37e75bb45eaa6067c604b83ae13d7" + hash: "82c61d8461001c19af7c2b458d427e0b" } Frame { msec: 2128 - hash: "4ee9e4c90c40dbc25a0ce884d9c2c37f" + hash: "e455d9ccffedaa708532bb69ad15871e" } Frame { msec: 2144 - hash: "cb7148ff6f611038c29af36c8552b8c2" + hash: "b9c6169ad08724fc70df30668dfe7509" } Frame { msec: 2160 - hash: "a591d8cb42570272dd264d5f1ce595ab" + hash: "a3fe5862be470470854d4157c1c027db" } Frame { msec: 2176 - hash: "4e61657405d32dbcd39d3637f8af0958" + hash: "6a3804bd5f4fd5f1c424615ceb620525" } Frame { msec: 2192 - hash: "9c7c1411dd5d3c1c8fb78e63e14061fe" + hash: "df0d72248310654a9cf47e707fe9e414" } Frame { msec: 2208 - hash: "ae83a37e99b578fa0872ed6bc2776bc0" + hash: "beb19f2b2979ab40b5ccf8c0fbe9b72f" } Frame { msec: 2224 - hash: "e8cb5a8a40c1e78c87c616f77d8de270" + hash: "be3449b49048b764bea68a76baa0fc75" } Frame { msec: 2240 - hash: "9df093e4bcfa32be5924a0ca70bdaa3b" + hash: "4a615cae9c8f85e7b8aecd4c9014f1eb" } Frame { msec: 2256 - hash: "40c358066d508143bee1446d12fe7b89" + hash: "b3c274f1a9d65684c0a55a544bf77810" } Frame { msec: 2272 - hash: "a929ed6efc7fc68b38635f3c74242f52" + hash: "31456b01fcfb60a77d2b9662c2fff7b6" } Frame { msec: 2288 - hash: "86ff721a3178b689ea47b6bc274a2b41" + hash: "2be5cf3f6158bf09659acc68b134846f" } Frame { msec: 2304 - hash: "ed1f680f6d05f54ceb75c9bae3a0716a" + hash: "5f9c725a11305f3e6c48ab332faabf50" } Frame { msec: 2320 - hash: "3f09a565df2beb51f366a1b3fb6adfe9" + hash: "277c2733c7245d045665198984b74224" } Frame { msec: 2336 - hash: "13468347bd26bab60f1db826fb17631c" + hash: "265b8342bc747fb43a5291df0f4ce48b" } Frame { msec: 2352 - hash: "9f7d085fea5788a457098973f17c36cb" + hash: "803b49ec31955b481009a51c64bcce65" } Frame { msec: 2368 - hash: "4114b93246155b3434200831b2995330" + hash: "a717b30ad50746cdf0fae82212ac88f0" } Frame { msec: 2384 - hash: "487171bd1430f74e3d51b5e215c34b5c" + hash: "65f46c8e69f24d060b5da6f866867f51" } Frame { msec: 2400 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "52f9e5d1106d00a950470076a50e4239" } Frame { msec: 2416 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "058a787aae2845308e68bb93f6a811e4" } Frame { msec: 2432 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "621985111c25994c0c0fe3635be67c1d" } Frame { msec: 2448 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2949b8185cefbaaf587a043d805cc670" } Frame { msec: 2464 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "d4a03127ae5047184c736617deeac92d" } Frame { msec: 2480 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "876c6c5ac4500de6234423bf6f3511d6" } Frame { msec: 2496 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "eb08aa172cfbdb696b6f672dfa7b6fff" } Frame { msec: 2512 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "a60c13b8f46faa0a35dbb539010550d4" } Frame { msec: 2528 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "c6f8786506e0326a5734ab8aea782f95" } Frame { msec: 2544 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "a49927f2aae24e692fc379f0ab6f4ee9" } Frame { msec: 2560 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2f1a2d50e1090b34ad1ea6a36eec4fe0" } Frame { msec: 2576 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "a5ee24d37be960a88684748b73dc75fe" } Frame { msec: 2592 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "28682389395b47ae33ceec1ba3beef4e" } Frame { msec: 2608 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "1869667b50b76d99716dd0d7849901fa" } Frame { msec: 2624 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2806ee1005193f55825aa6147583985f" } Frame { msec: 2640 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "c00589dce90e3ab2f2c8890f30f80d3d" } Frame { msec: 2656 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "1f1881f0a29525e380ecbcce15499fa4" } Frame { msec: 2672 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2a4c3ff764545a3899c864680f22f0a3" } Frame { msec: 2688 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2704 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2720 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2736 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2752 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2768 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2784 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2800 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2816 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2832 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2848 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2864 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "2685820514ce5d5729f3761b1eaa1682" } Frame { msec: 2880 image: "test-pathview.2.png" } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 310; y: 277 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 324; y: 279 + modifiers: 0 + sendToViewport: true + } Frame { msec: 2896 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "ce00c77e8ff1768b41f5585344af1c58" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 330; y: 281 + modifiers: 0 + sendToViewport: true } Frame { msec: 2912 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "24f401275fa6ec7d26234609792fe0b8" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 346; y: 283 + modifiers: 0 + sendToViewport: true } Frame { msec: 2928 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "d3c74863c627a1b922a6b6c4a24f8c40" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 358; y: 285 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 3 + button: 1 + buttons: 0 + x: 358; y: 285 + modifiers: 0 + sendToViewport: true } Frame { msec: 2944 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "64a3209e6adc737065e5d5c3202a7283" } Frame { msec: 2960 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "cf936ffe4330edefddb31c59368491fc" } Frame { msec: 2976 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "a67213db044bb876f737cd355fe54444" } Frame { msec: 2992 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "0f9e97057cbbd8071e0f5f61318bdf9c" } Frame { msec: 3008 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "c5f38d334df86ebb6ac4600c83eced20" } Frame { msec: 3024 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "6d8e6049a36eac4136dbdb5fb18d0650" } Frame { msec: 3040 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "8ee97cff4a632e6e297bd3bdac27b8d4" } Frame { msec: 3056 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "aca1fcd005d211d35245e64a44002c01" } Frame { msec: 3072 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "7076180bf0eb14a5e733be9320f1f009" } Frame { msec: 3088 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" - } - Mouse { - type: 2 - button: 1 - buttons: 1 - x: 728; y: 181 - modifiers: 0 - sendToViewport: true + hash: "e0a0545b3a0b6a0b07d3fa987e1d58b6" } Frame { msec: 3104 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "0294b098ce7f0d381542776320e52d2e" } Frame { msec: 3120 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" + hash: "36f8bcc42add38fe149e34a703cf8a02" } Frame { msec: 3136 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 727; y: 181 - modifiers: 0 - sendToViewport: true + hash: "631426bde50fd35d1da1c30d9878253e" } Frame { msec: 3152 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 723; y: 181 - modifiers: 0 - sendToViewport: true + hash: "a4d64c9d378138bedf63389e58d8f1d6" } Frame { msec: 3168 - hash: "7ba9783ce63db6ad6b5f725a4ecd4eb8" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 717; y: 184 - modifiers: 0 - sendToViewport: true + hash: "17fdf61bffd947c2e9898f5c4517fdf8" } Frame { msec: 3184 - hash: "6dcec6cdaa35eba74607ba64d6ea2ec0" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 705; y: 188 - modifiers: 0 - sendToViewport: true + hash: "653b8c7a55bc4ca763238098711eafa1" } Frame { msec: 3200 - hash: "16b7b4847fe86b25d8d6136106a4c400" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 686; y: 197 - modifiers: 0 - sendToViewport: true + hash: "89e15b3ee1b1fc945801e08cfcdba62c" } Frame { msec: 3216 - hash: "d946d55b19c99fa25bf1c04f2b71026a" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 661; y: 207 - modifiers: 0 - sendToViewport: true + hash: "7ea615af67336895e6cee6d3a39ff7de" } Frame { msec: 3232 - hash: "96f40f5071365cde769c733fd1ef5a24" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 626; y: 221 - modifiers: 0 - sendToViewport: true + hash: "88faee45db80f04ef1120c35057a5f7d" } Frame { msec: 3248 - hash: "7004058b95b7eab3ebba5c80c0923982" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 582; y: 235 - modifiers: 0 - sendToViewport: true + hash: "8cfe34047b29ac85e58d55e0f6e0b195" } Frame { msec: 3264 - hash: "2c78880237c414182f97f1709f1eef0f" - } - Mouse { - type: 5 - button: 0 - buttons: 1 - x: 532; y: 246 - modifiers: 0 - sendToViewport: true + hash: "39255546502fcb882005fe4c38c21fb0" } Frame { msec: 3280 - hash: "c90a15ec9f88008ca8b0ec0185444d71" - } - Mouse { - type: 3 - button: 1 - buttons: 0 - x: 532; y: 246 - modifiers: 0 - sendToViewport: true + hash: "6bf7a959a05fc27f651b2a3ba07de30d" } Frame { msec: 3296 - hash: "c90a15ec9f88008ca8b0ec0185444d71" + hash: "c2c61cb8dbbbd38827277ab32579c6da" } Frame { msec: 3312 - hash: "36461e2a4cd860cac32223b8ee73c657" + hash: "ff370d4b4e44c4cbacca96107105df21" } Frame { msec: 3328 - hash: "5f9b3ad9202fb02a4c6fea28c248ad22" + hash: "ccadd9e070d54de21c76397d18ad3de8" } Frame { msec: 3344 - hash: "d0d23c4e1ddb2d9ffa0ecc38030ae15c" + hash: "6302c39de00070b0a23f9dc87f74dd8d" } Frame { msec: 3360 - hash: "8e2e2d3eaf557c453f34016b6614e495" + hash: "7ab69e6d9809c78dc723609bd2761206" } Frame { msec: 3376 - hash: "7402c747fa7276293a0a72d48d342782" + hash: "c429cc724b39891805cf4c1448de60b3" } Frame { msec: 3392 - hash: "6090c30e4d722a32c083a25171fb11ff" + hash: "396ddf0b01e9fe7c2bfb220e64a0c7ec" } Frame { msec: 3408 - hash: "f770d940cf287fec4b0803f7310292a8" + hash: "7a519a4efeecef5e7623a270e458fb13" } Frame { msec: 3424 - hash: "558e4ce32df69357b70a8285b00fe347" + hash: "869d174a939e0638a1a22d5c8a010c14" } Frame { msec: 3440 - hash: "8814168503c9a72ea8d3fa1e503f33d9" + hash: "9ecd2cf4e3b42ff93bcbf4db9829666c" } Frame { msec: 3456 - hash: "6f5513d22e545096fadc6f5c4112902e" + hash: "b06b58b250d3df365806a3f8991d57f3" } Frame { msec: 3472 - hash: "43f11d8ac16fd3e8199e555528817e14" + hash: "7a6fb03feb2ae0af1f143daedd22a88b" } Frame { msec: 3488 - hash: "d64bafdbd26878a323dae918d5e0a36d" + hash: "e9fe338dbe7afb69f3870743b0a18805" } Frame { msec: 3504 - hash: "1c70bdddfc3751ae3864f008170f8b06" + hash: "04b8def2085e9ce4065b02b938915557" } Frame { msec: 3520 - hash: "bb7a18691fcd371e9d382b5bba4a0573" + hash: "7e6942f72012875ba83a1c9121e1f786" } Frame { msec: 3536 - hash: "547e15f5dea2d9aa3ed44640b25028b9" + hash: "291e2d79a79959d9c8c586b6bdc31689" } Frame { msec: 3552 - hash: "c11b86a256fac6be10b9a54564903d6f" + hash: "e490bc7fd92f486b964cca967bd33b38" } Frame { msec: 3568 - hash: "0ada2dc586894d5e37de2632d2b37b15" + hash: "0c9858e0445e25d2b12c84801de441cb" } Frame { msec: 3584 - hash: "0ae1a39ea196a0e734d80dbdea67b285" + hash: "72ba7a4aacb150e1e9c6de72cff82258" } Frame { msec: 3600 - hash: "3cb70e64f9ab8aad841326dc2d2f1615" + hash: "1daca95256842545a5b77bcc46782478" } Frame { msec: 3616 - hash: "a8f8b5ff19df9163ea628b589b675a5e" + hash: "869f3d16e203ad47f1ae7ca83e369b75" } Frame { msec: 3632 - hash: "26fcc73f477db0ea731bc18b00b4c791" + hash: "9cc9cb20aab3369f4e3c5259d291708c" } Frame { msec: 3648 - hash: "8702e49f3f26e1e21970e78c8aa4040a" + hash: "a507b957bab3efe2023a65f8c8b3540a" } Frame { msec: 3664 - hash: "1a482a39d02779d8733e348b713f2312" + hash: "9fce2a6cddd8b06a80ce16599b56caa6" } Frame { msec: 3680 - hash: "c728cc4a8e4d0a8d983514f86a92eae0" + hash: "2f85d3064968e3e7b669f733fad58459" } Frame { msec: 3696 - hash: "82360ab373b08bf6a5d9e9ea9d0d18aa" + hash: "6dd6fad85dc5317a22a05a8486317767" } Frame { msec: 3712 - hash: "6231a4bce6cfc1e26a9606cc041acdbc" + hash: "b0faa2ec225cd96fb6d2fd05dc66bed1" } Frame { msec: 3728 - hash: "6e3b48862fc749f15aa2dec1c17d1de0" + hash: "3188219f095c2a9ac7c0f6034463d769" } Frame { msec: 3744 - hash: "6c9e79a5692a3810b2a9058790f54cd7" + hash: "b269e9fe4d14537c8bef0b66effe7319" } Frame { msec: 3760 - hash: "0652c67fedda0d5e55858ddefff2da9e" + hash: "b269e9fe4d14537c8bef0b66effe7319" } Frame { msec: 3776 - hash: "3b058c0efeb3a9da54a1de72a1792a83" + hash: "b269e9fe4d14537c8bef0b66effe7319" } Frame { msec: 3792 - hash: "96e6fb39c8dbfe4a00bf116bf80aac4d" + hash: "b269e9fe4d14537c8bef0b66effe7319" + } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 174; y: 234 + modifiers: 0 + sendToViewport: true } Frame { msec: 3808 - hash: "979c0c78c41e0f337cfe1b384fbbe51a" + hash: "9480eb8761d4ce90971903fcfab1e09e" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 176; y: 236 + modifiers: 0 + sendToViewport: true } Frame { msec: 3824 - hash: "8be0d6987a6d12864f30336b249e4b16" + hash: "30a6ac631e1a3433f252f56ee4337cdc" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 179; y: 238 + modifiers: 0 + sendToViewport: true } Frame { msec: 3840 image: "test-pathview.3.png" } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 184; y: 243 + modifiers: 0 + sendToViewport: true + } Frame { msec: 3856 - hash: "31e665f804a52a4dc88eab5dba78ae5a" + hash: "ed07f9eea6cd2cd78a3e2479137f843d" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 185; y: 244 + modifiers: 0 + sendToViewport: true } Frame { msec: 3872 - hash: "b7d4cf5a6a3ac79da3be101b50b38bc2" + hash: "7a5b201cc8725dbf15d89907fffd4ee3" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 197; y: 250 + modifiers: 0 + sendToViewport: true } Frame { msec: 3888 - hash: "559b1b8467b611cdeb7f2ae660e3bf51" + hash: "bc2433b9e5f03cdbd35922d145a4ce59" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 213; y: 256 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 3 + button: 1 + buttons: 0 + x: 213; y: 256 + modifiers: 0 + sendToViewport: true } Frame { msec: 3904 - hash: "66abb5af85e793569382efb04744d0de" + hash: "d443f23aa5449d5f2b11c47feab5a0ae" } Frame { msec: 3920 - hash: "b64eff8bbea5a953d146333363825724" + hash: "c43f00d3ae4c8abbd20fc7157363b19d" } Frame { msec: 3936 - hash: "47b794c971c4d47baf15e1d63d65ac03" + hash: "22d6f5e9fdfe44e73020e6f504002b7c" } Frame { msec: 3952 - hash: "b3882fa14f3cb7428c660737656d7ea2" + hash: "4a9a285834aad5795adbefbe167028e2" } Frame { msec: 3968 - hash: "a6bd71c7d3a0f3f53674ea8e1334e560" + hash: "561a6c005950830acf2a45ab9a207346" } Frame { msec: 3984 - hash: "0926d3cd53aabb789686e34d91ef23dc" + hash: "b0387e3cfd455e1144d0bce9b51d6767" } Frame { msec: 4000 - hash: "914c4fa7264111b4a42c82a60701d652" + hash: "610237f67aa7e5f8d5b363b1612b4966" } Frame { msec: 4016 - hash: "84c1fa22440a61126b79c38605b6f9ca" + hash: "8034a5a7e0558d73051ea6c5bc750866" } Frame { msec: 4032 - hash: "b684fcf9f4725cfc02af0187454dfaf8" + hash: "0e4dc8a9c124b51c5f1225f4c6a9ec63" } Frame { msec: 4048 - hash: "2e94c1ca74af4eb836a0c505d131f263" + hash: "dc4e94522e8c64e9f2dbbf12a1f1aa3e" } Frame { msec: 4064 - hash: "5f04912674e1bcdb16176976d10ce995" + hash: "7466c076a95f2f6bbc2b6ce306773337" } Frame { msec: 4080 - hash: "aaf0bcef4a15aa1c699eaa1ce817c8ed" + hash: "787e2749905b97159fd0922c6cb388e2" } Frame { msec: 4096 - hash: "97fd5bdcfa367191fbd3689658ab3273" + hash: "1e510d01afad190ec21de253bd8b4821" } Frame { msec: 4112 - hash: "d76d6c59411636a0e9ac2e0c847b3fe3" + hash: "d740f40eb21be71ec70c00411d2ee76b" } Frame { msec: 4128 - hash: "9cb88a76c962623b1a9cf4e7093d6e54" + hash: "887a6f445af8fccf4932eed575a09cbb" } Frame { msec: 4144 - hash: "ec3d7075680296905b1bdd6fdd9fcc40" + hash: "fbb7e1d8cb9dd9016df0c33c69b1451a" } Frame { msec: 4160 - hash: "43c70dabc45ed059e8b876eb2ba5c66e" + hash: "5025e5f04a0807cb298037d6dda8c3af" } Frame { msec: 4176 - hash: "8f97ca5c3092a20009c5d00139105a22" + hash: "b9924f24f60c24087be165e8e385ebb0" } Frame { msec: 4192 - hash: "d0f225d4b03495218f7916698e254338" + hash: "2bab970787ac8b056401c8a73cb1a3c5" } Frame { msec: 4208 - hash: "f8725467353a8f27bc5570af157c93c7" + hash: "bda954bfafaa2915d760cf7a602b326f" + } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 187; y: 242 + modifiers: 0 + sendToViewport: true } Frame { msec: 4224 - hash: "749c8ca5c0a7774c81805b792e6b70e3" + hash: "9b109bb9e786a45a78849436ea32a484" } Frame { msec: 4240 - hash: "d353c4a8a5eecb1dce30f4a5b85b1ef4" + hash: "9b109bb9e786a45a78849436ea32a484" } Frame { msec: 4256 - hash: "a7105f3f1ddace730d0b4a12a3560208" + hash: "9b109bb9e786a45a78849436ea32a484" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 187; y: 243 + modifiers: 0 + sendToViewport: true } Frame { msec: 4272 - hash: "918f480af8a35f6074ff1e202dae2660" + hash: "9b109bb9e786a45a78849436ea32a484" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 199; y: 252 + modifiers: 0 + sendToViewport: true } Frame { msec: 4288 - hash: "ed98d08eb30db1b41aaf2a58f3b59398" + hash: "cc3c61f49a7b3c395670b86c8078a337" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 223; y: 262 + modifiers: 0 + sendToViewport: true } Frame { msec: 4304 - hash: "c362cf053b3749a44d1fc33483f9952b" + hash: "464d09b53b78fe5474d9c1d022bee9fd" + } + Mouse { + type: 5 + button: 0 + buttons: 1 + x: 251; y: 272 + modifiers: 0 + sendToViewport: true + } + Mouse { + type: 3 + button: 1 + buttons: 0 + x: 251; y: 272 + modifiers: 0 + sendToViewport: true } Frame { msec: 4320 - hash: "9b01b2c771ef86ff4a8ee3f6a4676e3c" + hash: "aab17f48ff506cda84543cbe0d8a1ce4" } Frame { msec: 4336 - hash: "70ccec3c9db95206b5589d43dcd52b13" + hash: "b7ba6c107f4085822a738120a913ba0c" } Frame { msec: 4352 - hash: "57e7397c6aadd0d4d5c9d9d5fcdd8fde" + hash: "751b79e202a70dcc9a86c3a1450172b8" } Frame { msec: 4368 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "bb03f969fd6987255ff113ef98ed2bb1" } Frame { msec: 4384 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "c33302b366441fa2d8753d5ce314cd37" } Frame { msec: 4400 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "4cdf32004382bcaca5a68cb92761caa2" } Frame { msec: 4416 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "d3fe18ea7dcbee0709a2041e50b87154" } Frame { msec: 4432 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "ac58a7adb0e7a354a058d7e9a7010c06" } Frame { msec: 4448 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "bdf8a8934a372ab49f4b6e9c95c7f591" } Frame { msec: 4464 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "d2e8b417b74ec5f6e23f0935a4d0aa98" } Frame { msec: 4480 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "0f94c6ca3ffbd730c2d813a991d21ca3" } Frame { msec: 4496 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "fb7728eebb2fa8f5255dc7435d20bbb6" } Frame { msec: 4512 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "c8211e8adcef525c296531a3d369f717" } Frame { msec: 4528 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "f24de36c85b87953977fa8b6456209dc" } Frame { msec: 4544 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "9ce7cf389af08cb1ba2534418f51857b" } Frame { msec: 4560 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "17d1f3ae0dba0bde222bb2483a403fbd" } Frame { msec: 4576 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "1748d75e229945012ece689b3784a02c" } Frame { msec: 4592 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "6786fa9e31d6f0a71a285c790aa5b008" } Frame { msec: 4608 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "f2a2ba33b41d8d522e8aab34c7da8f7b" } Frame { msec: 4624 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "aa53142d1b433ae9f748aef5cb7bef46" } Frame { msec: 4640 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "9c6802b2b0a419a4aaf9909c0f88c66e" } Frame { msec: 4656 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "206b11f2acd742d55ddd8acf7415bbeb" } Frame { msec: 4672 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "36876cf600cbf9c3b15f243617c9474e" } Frame { msec: 4688 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "1f5daf97294b490546657c5d9e12022e" } Frame { msec: 4704 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "637fc34fc2cf6139ba8809be54a2a0fc" } Frame { msec: 4720 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "9f824bd9e156980873619b1978f226bb" } Frame { msec: 4736 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "7002444129a5077ce5be44a5e2530328" } Frame { msec: 4752 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "42b7a44030ad4fc50ceb6a60bc97991e" } Frame { msec: 4768 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "ae986cac541033398076fb918136212e" } Frame { msec: 4784 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "6bdd9f764b1675e5b0feced8c2d831a6" } Frame { msec: 4800 @@ -1382,114 +1558,278 @@ VisualTest { } Frame { msec: 4816 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "07dfffe85adc4b52565e9ed156fa3ed6" } Frame { msec: 4832 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "c987bbe9fbf74bb6cf2686a5ee97c59a" } Frame { msec: 4848 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "19568159ec2282d5f150583baa0a8a94" } Frame { msec: 4864 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "5b176ef6bf70ff1a9805ca85b1b0c1a2" } Frame { msec: 4880 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "de716a8c15a46bf1621878794e968c53" } Frame { msec: 4896 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "241af9ab77c86cdb75f73339548604ad" } Frame { msec: 4912 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "afc7168ecb7fa7e3310ca818b75f7a1c" } Frame { msec: 4928 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "83bff911b502a34d139a724f686bb1f9" } Frame { msec: 4944 - hash: "299b24eae7720e1711744b23335bca8c" - } - Key { - type: 6 - key: 16777249 - modifiers: 0 - text: "" - autorep: false - count: 1 + hash: "f4d3fb54ae5be2b13065cd4316b06837" } Frame { msec: 4960 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "d29c7dfedf9dd355d60e394528b3b938" } Frame { msec: 4976 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "ddf23d860ea71ab4b407de1a5f913f74" } Frame { msec: 4992 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "a0dbb6ecbfd08f9ebdd641fea5dae16c" } Frame { msec: 5008 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "7ed3170e55e3c3c9561959ad4c56d326" } Frame { msec: 5024 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "dbde5f508aabc2d1f2ccfaf135efeca9" } Frame { msec: 5040 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "72039739be41bf63b3959bdc90ce25bb" } Frame { msec: 5056 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "417789daefe6bc01320db7803ae31d61" } Frame { msec: 5072 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "7e57dbddaf379f4316182048fa9e2d6f" } Frame { msec: 5088 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "aeca9a4df94d2b9ac2a713531a7d98f1" } Frame { msec: 5104 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "98ad6694f23678819020d6ac0161651c" } Frame { msec: 5120 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "b6eba3872da19ec677eee419ae9cccbc" } Frame { msec: 5136 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "e824909bfe7b6d54773bb218ba93e884" } Frame { msec: 5152 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "3be04f3ff6d948538f4472bc6bfadb0f" } Frame { msec: 5168 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "e05ff21dda1d978a2ac2eedd3826b6f7" } Frame { msec: 5184 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "8ee970b2b197c8d879a7b1703cbd4dcd" } Frame { msec: 5200 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "e583845e7719d2776c6362c34f77937c" } Frame { msec: 5216 - hash: "299b24eae7720e1711744b23335bca8c" + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5232 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5248 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5264 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5280 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5296 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5312 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5328 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5344 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5360 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5376 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5392 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5408 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5424 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5440 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5456 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5472 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5488 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5504 + hash: "593fd590531ccfb59d890b8043eaab9c" + } + Frame { + msec: 5520 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5536 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5552 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5568 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5584 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5600 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5616 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5632 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5648 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5664 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5680 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5696 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5712 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5728 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5744 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5760 + image: "test-pathview.5.png" + } + Frame { + msec: 5776 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5792 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5808 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5824 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5840 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5856 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5872 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5888 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" + } + Frame { + msec: 5904 + hash: "c0d0f62d9078f6be493d5545a2ae78ad" } } diff --git a/tests/auto/declarative/qmlvisual/qdeclarativepathview/test-pathview.qml b/tests/auto/declarative/qmlvisual/qdeclarativepathview/test-pathview.qml index 3bcab5a..e6e1a70 100644 --- a/tests/auto/declarative/qmlvisual/qdeclarativepathview/test-pathview.qml +++ b/tests/auto/declarative/qmlvisual/qdeclarativepathview/test-pathview.qml @@ -59,4 +59,9 @@ Rectangle { PathAttribute { name: "angle"; value: 45 } } } + + Column { + Rectangle { width: 20; height: 20; color: "red"; opacity: photoPathView.moving ? 1 : 0 } + Rectangle { width: 20; height: 20; color: "blue"; opacity: photoPathView.flicking ? 1 : 0 } + } } -- cgit v0.12 From c8f2b393bf168e7d30239e44d0cb8fda3f9be8a0 Mon Sep 17 00:00:00 2001 From: Harald Fernengel Date: Thu, 29 Jul 2010 13:26:07 +0200 Subject: Add license header Fixes the licenseCheck autotest --- tools/qml/startup/Logo.qml | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/tools/qml/startup/Logo.qml b/tools/qml/startup/Logo.qml index 9252223..8d9708d 100644 --- a/tools/qml/startup/Logo.qml +++ b/tools/qml/startup/Logo.qml @@ -1,3 +1,44 @@ +/**************************************************************************** +** +** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** All rights reserved. +** Contact: Nokia Corporation (qt-info@nokia.com) +** +** This file is part of the QtDeclarative module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the Technology Preview License Agreement accompanying +** this package. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPL included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 2.1 requirements +** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** In addition, as a special exception, Nokia gives you certain additional +** rights. These rights are described in the Nokia Qt LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** If you have questions regarding the use of this file, please contact +** Nokia at qt-info@nokia.com. +** +** +** +** +** +** +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + import Qt 4.7 Rectangle { -- cgit v0.12 From 1d26798c0882ac9be1059ab612533d1750a3ac7b Mon Sep 17 00:00:00 2001 From: Harald Fernengel Date: Thu, 29 Jul 2010 18:56:42 +0200 Subject: doc: Add a note about QCoreApplication::applicationDirPath --- doc/src/platforms/mac-differences.qdoc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/doc/src/platforms/mac-differences.qdoc b/doc/src/platforms/mac-differences.qdoc index 766c619..2501656 100644 --- a/doc/src/platforms/mac-differences.qdoc +++ b/doc/src/platforms/mac-differences.qdoc @@ -175,6 +175,9 @@ \l{http://developer.apple.com/documentation/CoreFoundation/Reference/CFBundleRef/index.html} {Apple's Developer Website}. + Note: QCoreApplication::applicationDirPath() can be used to determine + the path of the binary within the bundle. + \section2 Translating the Application Menu and Native Dialogs The items in the Application Menu will be merged correctly for -- cgit v0.12 From efa23362ede82f43b24107423a2cd7c169db3e39 Mon Sep 17 00:00:00 2001 From: Harald Fernengel Date: Thu, 29 Jul 2010 22:10:31 +0200 Subject: add license header --- tools/qml/startup/startup.qml | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/tools/qml/startup/startup.qml b/tools/qml/startup/startup.qml index 6792150..be67598 100644 --- a/tools/qml/startup/startup.qml +++ b/tools/qml/startup/startup.qml @@ -1,3 +1,44 @@ +/**************************************************************************** +** +** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** All rights reserved. +** Contact: Nokia Corporation (qt-info@nokia.com) +** +** This file is part of the QtDeclarative module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the Technology Preview License Agreement accompanying +** this package. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPL included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 2.1 requirements +** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** In addition, as a special exception, Nokia gives you certain additional +** rights. These rights are described in the Nokia Qt LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** If you have questions regarding the use of this file, please contact +** Nokia at qt-info@nokia.com. +** +** +** +** +** +** +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + import Qt 4.7 Rectangle { -- cgit v0.12 From eef2e72976f3f8d10a34c9dfb3f60f40616f4df9 Mon Sep 17 00:00:00 2001 From: Bea Lam Date: Fri, 30 Jul 2010 12:59:56 +1000 Subject: Update QML Documents example Task-number: QTBUG-12526 --- doc/src/declarative/pics/anatomy-component.png | Bin 16117 -> 4902 bytes doc/src/declarative/qdeclarativedocument.qdoc | 58 ++++++++++++---------- doc/src/snippets/declarative/qmldocuments.qml | 66 +++++++++++++++++++++++++ 3 files changed, 98 insertions(+), 26 deletions(-) create mode 100644 doc/src/snippets/declarative/qmldocuments.qml diff --git a/doc/src/declarative/pics/anatomy-component.png b/doc/src/declarative/pics/anatomy-component.png index 70ed983..6125b00 100644 Binary files a/doc/src/declarative/pics/anatomy-component.png and b/doc/src/declarative/pics/anatomy-component.png differ diff --git a/doc/src/declarative/qdeclarativedocument.qdoc b/doc/src/declarative/qdeclarativedocument.qdoc index a2ed205..f12e547 100644 --- a/doc/src/declarative/qdeclarativedocument.qdoc +++ b/doc/src/declarative/qdeclarativedocument.qdoc @@ -73,51 +73,57 @@ document - such as \c Rectangle and \c ListView - including those made within an import statements. QML does not import any modules by default, so at least one \c import statement must be present or no elements will be available! + +\section1 Documents as Component Definitions + A QML document defines a single, top-level \l {QDeclarativeComponent}{QML component}. A QML component is a template that is interpreted by the QML runtime to create an object with some predefined behaviour. As it is a template, a single QML component can be "run" multiple times to produce several objects, each of which are said to be \e instances of the component. Once created, instances are not dependent on the component that created them, so they can -operate on independent data. Here is an example of a simple "Button" component that is -instantiated four times, each with a different value for its \c text property. +operate on independent data. Here is an example of a simple "Button" component (defined +in a \c Button.qml file) that is instantiated four times by \c application.qml. +Each instance is created with a different value for its \c text property: -\raw HTML -
-\endraw -\code +\table +\row +\o Button.qml +\o application.qml + +\row +\o \snippet doc/src/snippets/declarative/qmldocuments.qml 0 +\o +\qml import Qt 4.7 -BorderImage { - property alias text: textElement.text - width: 100; height: 30; source: "images/toolbutton.sci" - - Text { - id: textElement - anchors.centerIn: parent - font.pointSize: 20 - style: Text.Raised - color: "white" - } +Column { + spacing: 10 + + Button { text: "Apple" } + Button { text: "Orange" } + Button { text: "Pear" } + Button { text: "Grape" } } -\endcode -\raw HTML - -\endraw +\endqml + \image anatomy-component.png -\raw HTML -
-\endraw + +\endtable Any snippet of QML code can become a component, just by placing it in the file ".qml" -where is the new element name, and begins with an uppercase letter. Note that +where is the new element name, and begins with an \bold uppercase letter. Note that the case of all characters in the are significant on some filesystems, notably UNIX filesystems. It is recommended that the case of the filename matches the case of the component name in QML exactly, regardless of the platform the QML will be deployed to. -These QML files automatically become available as new QML element types +These QML component files automatically become available as new QML element types to other QML components and applications in the same directory. + + +\section1 Inline Components + In addition to the top-level component that all QML documents define, and any reusable components placed in separate files, documents may also include \e inline components. Inline components are declared using the diff --git a/doc/src/snippets/declarative/qmldocuments.qml b/doc/src/snippets/declarative/qmldocuments.qml new file mode 100644 index 0000000..c19a658 --- /dev/null +++ b/doc/src/snippets/declarative/qmldocuments.qml @@ -0,0 +1,66 @@ +/**************************************************************************** +** +** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** All rights reserved. +** Contact: Nokia Corporation (qt-info@nokia.com) +** +** This file is part of the QtDeclarative module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the Technology Preview License Agreement accompanying +** this package. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 as published by the Free Software +** Foundation and appearing in the file LICENSE.LGPL included in the +** packaging of this file. Please review the following information to +** ensure the GNU Lesser General Public License version 2.1 requirements +** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** In addition, as a special exception, Nokia gives you certain additional +** rights. These rights are described in the Nokia Qt LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** If you have questions regarding the use of this file, please contact +** Nokia at qt-info@nokia.com. +** +** +** +** +** +** +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ +//![0] +import Qt 4.7 + +Rectangle { + property alias text: textItem.text + + width: 100; height: 30 + border.width: 1 + radius: 5 + smooth: true + + gradient: Gradient { + GradientStop { position: 0.0; color: "darkGray" } + GradientStop { position: 0.5; color: "black" } + GradientStop { position: 1.0; color: "darkGray" } + } + + Text { + id: textItem + anchors.centerIn: parent + font.pointSize: 20 + color: "white" + } + +} +//![0] -- cgit v0.12 From 765c263d538b258f223dfb6bd7f62dbd19853db6 Mon Sep 17 00:00:00 2001 From: Bea Lam Date: Fri, 30 Jul 2010 13:01:23 +1000 Subject: Mention scope of id uniqueness Task-number: QTBUG-12528 --- doc/src/declarative/qdeclarativedocument.qdoc | 4 ++++ doc/src/declarative/qdeclarativeintro.qdoc | 7 ++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/doc/src/declarative/qdeclarativedocument.qdoc b/doc/src/declarative/qdeclarativedocument.qdoc index f12e547..068297a 100644 --- a/doc/src/declarative/qdeclarativedocument.qdoc +++ b/doc/src/declarative/qdeclarativedocument.qdoc @@ -73,6 +73,10 @@ document - such as \c Rectangle and \c ListView - including those made within an import statements. QML does not import any modules by default, so at least one \c import statement must be present or no elements will be available! +Each \c id value in a QML document must be unique within that document. They +do not need to be unique across different documents as id values are +resolved according to the document scope. + \section1 Documents as Component Definitions diff --git a/doc/src/declarative/qdeclarativeintro.qdoc b/doc/src/declarative/qdeclarativeintro.qdoc index 75055d8..fa42f59 100644 --- a/doc/src/declarative/qdeclarativeintro.qdoc +++ b/doc/src/declarative/qdeclarativeintro.qdoc @@ -87,6 +87,10 @@ Rectangle { width: 100; height: 100 } When multiple property/value pairs are specified on a single line, they must be separated by a semicolon. +The \c import statement imports the \c Qt \l{QML Modules}{module}, which contains all of the +standard \l {QML Elements}. Without this import statement, the \l Rectangle +and \l Image elements would not be available. + \section1 Expressions In addition to assigning values to properties, you can also assign @@ -181,7 +185,8 @@ Item { \section3 The \c id property -Each object can be given a special unique property called an \e id. Assigning an id enables the object +Each object can be given a special unique property called an \e id. No other object within the +same \l{QML Documents}{QML document} can have the same \c id value. Assigning an id enables the object to be referred to by other objects and scripts. The first Rectangle element below has an \e id, "myRect". The second Rectange element defines its -- cgit v0.12 From ca61cd321b867d912bd13b0530fbf2847d1c593c Mon Sep 17 00:00:00 2001 From: Bea Lam Date: Fri, 30 Jul 2010 15:34:15 +1000 Subject: Add missing image Task-number: QTBUG-12529 --- doc/src/images/qml-pathview-example.png | Bin 0 -> 22077 bytes src/declarative/graphicsitems/qdeclarativepathview.cpp | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) create mode 100644 doc/src/images/qml-pathview-example.png diff --git a/doc/src/images/qml-pathview-example.png b/doc/src/images/qml-pathview-example.png new file mode 100644 index 0000000..c874c5c Binary files /dev/null and b/doc/src/images/qml-pathview-example.png differ diff --git a/src/declarative/graphicsitems/qdeclarativepathview.cpp b/src/declarative/graphicsitems/qdeclarativepathview.cpp index 5dcf1b7..06ac275 100644 --- a/src/declarative/graphicsitems/qdeclarativepathview.cpp +++ b/src/declarative/graphicsitems/qdeclarativepathview.cpp @@ -364,7 +364,7 @@ void QDeclarativePathViewPrivate::regenerate() to set \e {clip: true} in order to have the out of view items clipped nicely. - \sa Path + \sa Path, {declarative/modelviews/pathview}{PathView example} */ QDeclarativePathView::QDeclarativePathView(QDeclarativeItem *parent) -- cgit v0.12