summaryrefslogtreecommitdiffstats
path: root/src/declarative
diff options
context:
space:
mode:
Diffstat (limited to 'src/declarative')
-rw-r--r--src/declarative/QmlChanges.txt10
-rw-r--r--src/declarative/graphicsitems/qdeclarativeeffects.cpp4
-rw-r--r--src/declarative/graphicsitems/qdeclarativeevents.cpp1
-rw-r--r--src/declarative/graphicsitems/qdeclarativeflickable.cpp138
-rw-r--r--src/declarative/graphicsitems/qdeclarativeflickable_p.h37
-rw-r--r--src/declarative/graphicsitems/qdeclarativeflickable_p_p.h8
-rw-r--r--src/declarative/graphicsitems/qdeclarativegridview.cpp29
-rw-r--r--src/declarative/graphicsitems/qdeclarativeimage.cpp12
-rw-r--r--src/declarative/graphicsitems/qdeclarativeimage_p.h1
-rw-r--r--src/declarative/graphicsitems/qdeclarativeitem.cpp8
-rw-r--r--src/declarative/graphicsitems/qdeclarativeitem_p.h4
-rw-r--r--src/declarative/graphicsitems/qdeclarativelistview.cpp42
-rw-r--r--src/declarative/graphicsitems/qdeclarativeparticles.cpp12
-rw-r--r--src/declarative/graphicsitems/qdeclarativepathview.cpp6
-rw-r--r--src/declarative/graphicsitems/qdeclarativepositioners_p.h2
-rw-r--r--src/declarative/graphicsitems/qdeclarativescalegrid_p_p.h2
-rw-r--r--src/declarative/graphicsitems/qdeclarativetextinput.cpp2
-rw-r--r--src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp2
-rw-r--r--src/declarative/graphicsitems/qdeclarativewebview.cpp3
-rw-r--r--src/declarative/qml/parser/qdeclarativejs.g45
-rw-r--r--src/declarative/qml/parser/qdeclarativejsast_p.h11
-rw-r--r--src/declarative/qml/parser/qdeclarativejsgrammar.cpp1595
-rw-r--r--src/declarative/qml/parser/qdeclarativejsgrammar_p.h33
-rw-r--r--src/declarative/qml/parser/qdeclarativejslexer.cpp2
-rw-r--r--src/declarative/qml/parser/qdeclarativejsparser.cpp424
-rw-r--r--src/declarative/qml/parser/qdeclarativejsparser_p.h4
-rw-r--r--src/declarative/qml/qdeclarativebinding.cpp16
-rw-r--r--src/declarative/qml/qdeclarativebinding_p.h26
-rw-r--r--src/declarative/qml/qdeclarativebinding_p_p.h4
-rw-r--r--src/declarative/qml/qdeclarativeboundsignal.cpp4
-rw-r--r--src/declarative/qml/qdeclarativecompiledbindings.cpp12
-rw-r--r--src/declarative/qml/qdeclarativecompiler.cpp28
-rw-r--r--src/declarative/qml/qdeclarativecompiler_p.h3
-rw-r--r--src/declarative/qml/qdeclarativecomponent.cpp6
-rw-r--r--src/declarative/qml/qdeclarativeengine.cpp33
-rw-r--r--src/declarative/qml/qdeclarativeengine_p.h3
-rw-r--r--src/declarative/qml/qdeclarativeenginedebug.cpp6
-rw-r--r--src/declarative/qml/qdeclarativeenginedebug_p.h2
-rw-r--r--src/declarative/qml/qdeclarativeextensioninterface.h3
-rw-r--r--src/declarative/qml/qdeclarativeextensionplugin.cpp16
-rw-r--r--src/declarative/qml/qdeclarativeextensionplugin.h3
-rw-r--r--src/declarative/qml/qdeclarativeglobal_p.h2
-rw-r--r--src/declarative/qml/qdeclarativelist.cpp115
-rw-r--r--src/declarative/qml/qdeclarativemetatype.cpp2
-rw-r--r--src/declarative/qml/qdeclarativeobjectscriptclass.cpp4
-rw-r--r--src/declarative/qml/qdeclarativeproperty.cpp (renamed from src/declarative/qml/qdeclarativemetaproperty.cpp)412
-rw-r--r--src/declarative/qml/qdeclarativeproperty.h (renamed from src/declarative/qml/qdeclarativemetaproperty.h)87
-rw-r--r--src/declarative/qml/qdeclarativeproperty_p.h (renamed from src/declarative/qml/qdeclarativemetaproperty_p.h)44
-rw-r--r--src/declarative/qml/qdeclarativepropertyvalueinterceptor.cpp2
-rw-r--r--src/declarative/qml/qdeclarativepropertyvalueinterceptor.h4
-rw-r--r--src/declarative/qml/qdeclarativepropertyvaluesource.cpp2
-rw-r--r--src/declarative/qml/qdeclarativepropertyvaluesource.h4
-rw-r--r--src/declarative/qml/qdeclarativescript.cpp1
-rw-r--r--src/declarative/qml/qdeclarativevaluetype.cpp18
-rw-r--r--src/declarative/qml/qdeclarativevaluetype_p.h24
-rw-r--r--src/declarative/qml/qdeclarativevme.cpp28
-rw-r--r--src/declarative/qml/qdeclarativevmemetaobject.cpp2
-rw-r--r--src/declarative/qml/qml.pri6
-rw-r--r--src/declarative/util/qdeclarativeanimation.cpp314
-rw-r--r--src/declarative/util/qdeclarativeanimation_p.h52
-rw-r--r--src/declarative/util/qdeclarativeanimation_p_p.h32
-rw-r--r--src/declarative/util/qdeclarativebehavior.cpp13
-rw-r--r--src/declarative/util/qdeclarativebehavior_p.h2
-rw-r--r--src/declarative/util/qdeclarativebind.cpp4
-rw-r--r--src/declarative/util/qdeclarativeconnection.cpp287
-rw-r--r--src/declarative/util/qdeclarativeconnections.cpp245
-rw-r--r--src/declarative/util/qdeclarativeconnections_p.h (renamed from src/declarative/util/qdeclarativeconnection_p.h)43
-rw-r--r--src/declarative/util/qdeclarativeeasefollow.cpp7
-rw-r--r--src/declarative/util/qdeclarativeeasefollow_p.h4
-rw-r--r--src/declarative/util/qdeclarativefontloader.cpp1
-rw-r--r--src/declarative/util/qdeclarativelistmodel.cpp2
-rw-r--r--src/declarative/util/qdeclarativelistmodel_p.h2
-rw-r--r--src/declarative/util/qdeclarativepackage.cpp2
-rw-r--r--src/declarative/util/qdeclarativepropertychanges.cpp30
-rw-r--r--src/declarative/util/qdeclarativespringfollow.cpp5
-rw-r--r--src/declarative/util/qdeclarativespringfollow_p.h2
-rw-r--r--src/declarative/util/qdeclarativestate.cpp6
-rw-r--r--src/declarative/util/qdeclarativestate_p.h6
-rw-r--r--src/declarative/util/qdeclarativestate_p_p.h8
-rw-r--r--src/declarative/util/qdeclarativestategroup.cpp3
-rw-r--r--src/declarative/util/qdeclarativestateoperations.cpp167
-rw-r--r--src/declarative/util/qdeclarativestateoperations_p.h34
-rw-r--r--src/declarative/util/qdeclarativesystempalette.cpp1
-rw-r--r--src/declarative/util/qdeclarativetimer.cpp1
-rw-r--r--src/declarative/util/qdeclarativetransition.cpp2
-rw-r--r--src/declarative/util/qdeclarativetransition_p.h2
-rw-r--r--src/declarative/util/qdeclarativetransitionmanager.cpp22
-rw-r--r--src/declarative/util/qdeclarativeutilmodule.cpp6
-rw-r--r--src/declarative/util/qdeclarativexmllistmodel.cpp21
-rw-r--r--src/declarative/util/qdeclarativexmllistmodel_p.h2
-rw-r--r--src/declarative/util/util.pri4
91 files changed, 2781 insertions, 1910 deletions
diff --git a/src/declarative/QmlChanges.txt b/src/declarative/QmlChanges.txt
index cf1080b..34e4834 100644
--- a/src/declarative/QmlChanges.txt
+++ b/src/declarative/QmlChanges.txt
@@ -1,7 +1,17 @@
=============================================================================
The changes below are pre Qt 4.7.0 alpha
+Flickable: renamed viewportWidth -> contentWidth
+Flickable: renamed viewportHeight -> contentHeight
+Flickable: renamed viewportX -> contentX
+Flickable: renamed viewportY -> contentY
+Removed Flickable.reportedVelocitySmoothing
Renamed MouseRegion -> MouseArea
+Connection: syntax and rename:
+ Connection { sender: a; signal: foo(); script: xxx }
+ Connection { sender: a; signal: bar(); script: yyy }
+ becomes:
+ Connections { target: a; onFoo: xxx; onBar: yyy }
QmlView
-------
diff --git a/src/declarative/graphicsitems/qdeclarativeeffects.cpp b/src/declarative/graphicsitems/qdeclarativeeffects.cpp
index efab24e..ea1f9cc 100644
--- a/src/declarative/graphicsitems/qdeclarativeeffects.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeeffects.cpp
@@ -45,6 +45,7 @@
/*!
\qmlclass Blur QGraphicsBlurEffect
+ \since 4.7
\brief The Blur object provides a blur effect.
A blur effect blurs the source item. This effect is useful for reducing details;
@@ -80,6 +81,7 @@
/*!
\qmlclass Colorize QGraphicsColorizeEffect
+ \since 4.7
\brief The Colorize object provides a colorize effect.
A colorize effect renders the source item with a tint of its color.
@@ -106,6 +108,7 @@
/*!
\qmlclass DropShadow QGraphicsDropShadowEffect
+ \since 4.7
\brief The DropShadow object provides a drop shadow effect.
A drop shadow effect renders the source item with a drop shadow. The color of
@@ -147,6 +150,7 @@
/*!
\qmlclass Opacity QGraphicsOpacityEffect
+ \since 4.7
\brief The Opacity object provides an opacity effect.
An opacity effect renders the source with an opacity. This effect is useful
diff --git a/src/declarative/graphicsitems/qdeclarativeevents.cpp b/src/declarative/graphicsitems/qdeclarativeevents.cpp
index d2cbb54..8be2f40 100644
--- a/src/declarative/graphicsitems/qdeclarativeevents.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeevents.cpp
@@ -114,6 +114,7 @@ Item {
/*!
\qmlclass MouseEvent QDeclarativeMouseEvent
+ \since 4.7
\brief The MouseEvent object provides information about a mouse event.
The position of the mouse can be found via the x and y properties.
diff --git a/src/declarative/graphicsitems/qdeclarativeflickable.cpp b/src/declarative/graphicsitems/qdeclarativeflickable.cpp
index 9f19f53..c54ddd0 100644
--- a/src/declarative/graphicsitems/qdeclarativeflickable.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeflickable.cpp
@@ -128,7 +128,7 @@ QDeclarativeFlickablePrivate::QDeclarativeFlickablePrivate()
, vWidth(-1), vHeight(-1), overShoot(true), flicked(false), moving(false), stealMouse(false)
, pressed(false), atXEnd(false), atXBeginning(true), atYEnd(false), atYBeginning(true)
, interactive(true), deceleration(500), maxVelocity(2000), reportedVelocitySmoothing(100)
- , delayedPressEvent(0), delayedPressTarget(0), pressDelay(0), fixupDuration(200)
+ , delayedPressEvent(0), delayedPressTarget(0), pressDelay(0), fixupDuration(600)
, horizontalVelocity(this), verticalVelocity(this), vTime(0), visibleArea(0)
, flickDirection(QDeclarativeFlickable::AutoFlickDirection)
{
@@ -142,12 +142,29 @@ void QDeclarativeFlickablePrivate::init()
QObject::connect(&timeline, SIGNAL(completed()), q, SLOT(movementEnding()));
q->setAcceptedMouseButtons(Qt::LeftButton);
q->setFiltersChildEvents(true);
- QObject::connect(viewport, SIGNAL(xChanged()), q, SIGNAL(positionXChanged()));
- QObject::connect(viewport, SIGNAL(yChanged()), q, SIGNAL(positionYChanged()));
+ QObject::connect(viewport, SIGNAL(xChanged()), q, SIGNAL(contentXChanged()));
+ QObject::connect(viewport, SIGNAL(yChanged()), q, SIGNAL(contentYChanged()));
QObject::connect(q, SIGNAL(heightChanged()), q, SLOT(heightChange()));
QObject::connect(q, SIGNAL(widthChanged()), q, SLOT(widthChange()));
}
+/*
+ Returns the amount to overshoot by given a velocity.
+ Will be roughly in range 0 - size/4
+*/
+qreal QDeclarativeFlickablePrivate::overShootDistance(qreal velocity, qreal size)
+{
+ Q_Q(QDeclarativeFlickable);
+ if (maxVelocity <= 0)
+ return 0.0;
+
+ velocity = qAbs(velocity);
+ if (velocity > maxVelocity)
+ velocity = maxVelocity;
+ qreal dist = size / 4 * velocity / maxVelocity;
+ return dist;
+}
+
void QDeclarativeFlickablePrivate::flickX(qreal velocity)
{
Q_Q(QDeclarativeFlickable);
@@ -156,12 +173,12 @@ void QDeclarativeFlickablePrivate::flickX(qreal velocity)
if (velocity > 0) {
const qreal minX = q->minXExtent();
if (_moveX.value() < minX)
- maxDistance = qAbs(minX -_moveX.value() + (overShoot?30:0));
+ maxDistance = qAbs(minX -_moveX.value() + (overShoot?overShootDistance(velocity,q->width()):0));
flickTargetX = minX;
} else {
const qreal maxX = q->maxXExtent();
if (_moveX.value() > maxX)
- maxDistance = qAbs(maxX - _moveX.value()) + (overShoot?30:0);
+ maxDistance = qAbs(maxX - _moveX.value()) + (overShoot?overShootDistance(velocity,q->width()):0);
flickTargetX = maxX;
}
if (maxDistance > 0) {
@@ -194,12 +211,12 @@ void QDeclarativeFlickablePrivate::flickY(qreal velocity)
if (velocity > 0) {
const qreal minY = q->minYExtent();
if (_moveY.value() < minY)
- maxDistance = qAbs(minY -_moveY.value() + (overShoot?30:0));
+ maxDistance = qAbs(minY -_moveY.value() + (overShoot?overShootDistance(velocity,q->height()):0));
flickTargetY = minY;
} else {
const qreal maxY = q->maxYExtent();
if (_moveY.value() > maxY)
- maxDistance = qAbs(maxY - _moveY.value()) + (overShoot?30:0);
+ maxDistance = qAbs(maxY - _moveY.value()) + (overShoot?overShootDistance(velocity,q->height()):0);
flickTargetY = maxY;
}
if (maxDistance > 0) {
@@ -233,18 +250,24 @@ void QDeclarativeFlickablePrivate::fixupX()
if (_moveX.value() > q->minXExtent() || (q->maxXExtent() > q->minXExtent())) {
timeline.reset(_moveX);
if (_moveX.value() != q->minXExtent()) {
- if (fixupDuration)
- timeline.move(_moveX, q->minXExtent(), QEasingCurve(QEasingCurve::InOutQuad), fixupDuration);
- else
- _moveY.setValue(q->minYExtent());
+ if (fixupDuration) {
+ qreal dist = q->minXExtent() - _moveX;
+ timeline.move(_moveX, q->minXExtent() - dist/2, QEasingCurve(QEasingCurve::InQuad), fixupDuration/4);
+ timeline.move(_moveX, q->minXExtent(), QEasingCurve(QEasingCurve::OutQuint), 3*fixupDuration/4);
+ } else {
+ _moveX.setValue(q->minXExtent());
+ }
}
//emit flickingChanged();
} else if (_moveX.value() < q->maxXExtent()) {
timeline.reset(_moveX);
- if (fixupDuration)
- timeline.move(_moveX, q->maxXExtent(), QEasingCurve(QEasingCurve::InOutQuad), fixupDuration);
- else
- _moveY.setValue(q->maxYExtent());
+ if (fixupDuration) {
+ qreal dist = q->maxXExtent() - _moveX;
+ timeline.move(_moveX, q->maxXExtent() - dist/2, QEasingCurve(QEasingCurve::InQuad), fixupDuration/4);
+ timeline.move(_moveX, q->maxXExtent(), QEasingCurve(QEasingCurve::OutQuint), 3*fixupDuration/4);
+ } else {
+ _moveX.setValue(q->maxXExtent());
+ }
//emit flickingChanged();
} else {
flicked = false;
@@ -272,18 +295,24 @@ void QDeclarativeFlickablePrivate::fixupY()
if (_moveY.value() > q->minYExtent() || (q->maxYExtent() > q->minYExtent())) {
timeline.reset(_moveY);
if (_moveY.value() != q->minYExtent()) {
- if (fixupDuration)
- timeline.move(_moveY, q->minYExtent(), QEasingCurve(QEasingCurve::InOutQuad), fixupDuration);
- else
+ if (fixupDuration) {
+ qreal dist = q->minYExtent() - _moveY;
+ timeline.move(_moveY, q->minYExtent() - dist/2, QEasingCurve(QEasingCurve::InQuad), fixupDuration/4);
+ timeline.move(_moveY, q->minYExtent(), QEasingCurve(QEasingCurve::OutQuint), 3*fixupDuration/4);
+ } else {
_moveY.setValue(q->minYExtent());
+ }
}
//emit flickingChanged();
} else if (_moveY.value() < q->maxYExtent()) {
timeline.reset(_moveY);
- if (fixupDuration)
- timeline.move(_moveY, q->maxYExtent(), QEasingCurve(QEasingCurve::InOutQuad), fixupDuration);
- else
+ if (fixupDuration) {
+ qreal dist = q->maxYExtent() - _moveY;
+ timeline.move(_moveY, q->maxYExtent() - dist/2, QEasingCurve(QEasingCurve::InQuad), fixupDuration/4);
+ timeline.move(_moveY, q->maxYExtent(), QEasingCurve(QEasingCurve::OutQuint), 3*fixupDuration/4);
+ } else {
_moveY.setValue(q->maxYExtent());
+ }
//emit flickingChanged();
} else {
flicked = false;
@@ -336,6 +365,7 @@ void QDeclarativeFlickablePrivate::updateBeginningEnd()
/*!
\qmlclass Flickable QDeclarativeFlickable
+ \since 4.7
\brief The Flickable item provides a surface that can be "flicked".
\inherits Item
@@ -343,7 +373,7 @@ void QDeclarativeFlickablePrivate::updateBeginningEnd()
\code
Flickable {
- width: 200; height: 200; viewportWidth: image.width; viewportHeight: image.height
+ width: 200; height: 200; contentWidth: image.width; contentHeight: image.height
Image { id: image; source: "bigimage.png" }
}
\endcode
@@ -429,20 +459,20 @@ QDeclarativeFlickable::~QDeclarativeFlickable()
}
/*!
- \qmlproperty int Flickable::viewportX
- \qmlproperty int Flickable::viewportY
+ \qmlproperty int Flickable::contentX
+ \qmlproperty int Flickable::contentY
These properties hold the surface coordinate currently at the top-left
corner of the Flickable. For example, if you flick an image up 100 pixels,
- \c yPosition will be 100.
+ \c contentY will be 100.
*/
-qreal QDeclarativeFlickable::viewportX() const
+qreal QDeclarativeFlickable::contentX() const
{
Q_D(const QDeclarativeFlickable);
return -d->_moveX.value();
}
-void QDeclarativeFlickable::setViewportX(qreal pos)
+void QDeclarativeFlickable::setContentX(qreal pos)
{
Q_D(QDeclarativeFlickable);
pos = qRound(pos);
@@ -454,13 +484,13 @@ void QDeclarativeFlickable::setViewportX(qreal pos)
}
}
-qreal QDeclarativeFlickable::viewportY() const
+qreal QDeclarativeFlickable::contentY() const
{
Q_D(const QDeclarativeFlickable);
return -d->_moveY.value();
}
-void QDeclarativeFlickable::setViewportY(qreal pos)
+void QDeclarativeFlickable::setContentY(qreal pos)
{
Q_D(QDeclarativeFlickable);
pos = qRound(pos);
@@ -506,12 +536,10 @@ void QDeclarativeFlickable::setInteractive(bool interactive)
/*!
\qmlproperty real Flickable::horizontalVelocity
\qmlproperty real Flickable::verticalVelocity
- \qmlproperty real Flickable::reportedVelocitySmoothing
The instantaneous velocity of movement along the x and y axes, in pixels/sec.
The reported velocity is smoothed to avoid erratic output.
- reportedVelocitySmoothing determines how much smoothing is applied.
*/
qreal QDeclarativeFlickable::horizontalVelocity() const
{
@@ -584,8 +612,8 @@ QDeclarativeFlickableVisibleArea *QDeclarativeFlickable::visibleArea()
\list
\o AutoFlickDirection (default) - allows flicking vertically if the
- \e viewportHeight is not equal to the \e height of the Flickable.
- Allows flicking horizontally if the \e viewportWidth is not equal
+ \e contentHeight is not equal to the \e height of the Flickable.
+ Allows flicking horizontally if the \e contentWidth is not equal
to the \e width of the Flickable.
\o HorizontalFlick - allows flicking horizontally.
\o VerticalFlick - allows flicking vertically.
@@ -968,10 +996,10 @@ QDeclarativeListProperty<QDeclarativeItem> QDeclarativeFlickable::flickableChild
/*!
\qmlproperty bool Flickable::overShoot
- This property holds the number of pixels the surface may overshoot the
+ This property holds whether the surface may overshoot the
Flickable's boundaries when flicked.
- If overShoot is non-zero the contents can be flicked beyond the boundary
+ If overShoot is true the contents can be flicked beyond the boundary
of the Flickable before being moved back to the boundary. This provides
the feeling that the edges of the view are soft, rather than a hard
physical boundary.
@@ -992,26 +1020,26 @@ void QDeclarativeFlickable::setOverShoot(bool o)
}
/*!
- \qmlproperty int Flickable::viewportWidth
- \qmlproperty int Flickable::viewportHeight
+ \qmlproperty int Flickable::contentWidth
+ \qmlproperty int Flickable::contentHeight
- The dimensions of the viewport (the surface controlled by Flickable). Typically this
+ The dimensions of the content (the surface controlled by Flickable). Typically this
should be set to the combined size of the items placed in the Flickable.
\code
Flickable {
- width: 320; height: 480; viewportWidth: image.width; viewportHeight: image.height
+ width: 320; height: 480; contentWidth: image.width; contentHeight: image.height
Image { id: image; source: "bigimage.png" }
}
\endcode
*/
-qreal QDeclarativeFlickable::viewportWidth() const
+qreal QDeclarativeFlickable::contentWidth() const
{
Q_D(const QDeclarativeFlickable);
return d->vWidth;
}
-void QDeclarativeFlickable::setViewportWidth(qreal w)
+void QDeclarativeFlickable::setContentWidth(qreal w)
{
Q_D(QDeclarativeFlickable);
if (d->vWidth == w)
@@ -1024,7 +1052,7 @@ void QDeclarativeFlickable::setViewportWidth(qreal w)
// Make sure that we're entirely in view.
if (!d->pressed)
d->fixupX();
- emit viewportWidthChanged();
+ emit contentWidthChanged();
d->updateBeginningEnd();
}
@@ -1033,7 +1061,7 @@ void QDeclarativeFlickable::widthChange()
Q_D(QDeclarativeFlickable);
if (d->vWidth < 0) {
d->viewport->setWidth(width());
- emit viewportWidthChanged();
+ emit contentWidthChanged();
}
d->updateBeginningEnd();
}
@@ -1043,18 +1071,18 @@ void QDeclarativeFlickable::heightChange()
Q_D(QDeclarativeFlickable);
if (d->vHeight < 0) {
d->viewport->setHeight(height());
- emit viewportHeightChanged();
+ emit contentHeightChanged();
}
d->updateBeginningEnd();
}
-qreal QDeclarativeFlickable::viewportHeight() const
+qreal QDeclarativeFlickable::contentHeight() const
{
Q_D(const QDeclarativeFlickable);
return d->vHeight;
}
-void QDeclarativeFlickable::setViewportHeight(qreal h)
+void QDeclarativeFlickable::setContentHeight(qreal h)
{
Q_D(QDeclarativeFlickable);
if (d->vHeight == h)
@@ -1067,7 +1095,7 @@ void QDeclarativeFlickable::setViewportHeight(qreal h)
// Make sure that we're entirely in view.
if (!d->pressed)
d->fixupY();
- emit viewportHeightChanged();
+ emit contentHeightChanged();
d->updateBeginningEnd();
}
@@ -1259,22 +1287,6 @@ void QDeclarativeFlickable::setPressDelay(int delay)
emit pressDelayChanged();
}
-qreal QDeclarativeFlickable::reportedVelocitySmoothing() const
-{
- Q_D(const QDeclarativeFlickable);
- return d->reportedVelocitySmoothing;
-}
-
-void QDeclarativeFlickable::setReportedVelocitySmoothing(qreal reportedVelocitySmoothing)
-{
- Q_D(QDeclarativeFlickable);
- Q_ASSERT(reportedVelocitySmoothing >= 0);
- if (reportedVelocitySmoothing == d->reportedVelocitySmoothing)
- return;
- d->reportedVelocitySmoothing = reportedVelocitySmoothing;
- emit reportedVelocitySmoothingChanged(reportedVelocitySmoothing);
-}
-
/*!
\qmlproperty bool Flickable::moving
diff --git a/src/declarative/graphicsitems/qdeclarativeflickable_p.h b/src/declarative/graphicsitems/qdeclarativeflickable_p.h
index 19fb2a9..4617688 100644
--- a/src/declarative/graphicsitems/qdeclarativeflickable_p.h
+++ b/src/declarative/graphicsitems/qdeclarativeflickable_p.h
@@ -56,14 +56,13 @@ class Q_DECLARATIVE_EXPORT QDeclarativeFlickable : public QDeclarativeItem
{
Q_OBJECT
- Q_PROPERTY(qreal viewportWidth READ viewportWidth WRITE setViewportWidth NOTIFY viewportWidthChanged)
- Q_PROPERTY(qreal viewportHeight READ viewportHeight WRITE setViewportHeight NOTIFY viewportHeightChanged)
- Q_PROPERTY(qreal viewportX READ viewportX WRITE setViewportX NOTIFY positionXChanged)
- Q_PROPERTY(qreal viewportY READ viewportY WRITE setViewportY NOTIFY positionYChanged)
+ Q_PROPERTY(qreal contentWidth READ contentWidth WRITE setContentWidth NOTIFY contentWidthChanged)
+ Q_PROPERTY(qreal contentHeight READ contentHeight WRITE setContentHeight NOTIFY contentHeightChanged)
+ Q_PROPERTY(qreal contentX READ contentX WRITE setContentX NOTIFY contentXChanged)
+ Q_PROPERTY(qreal contentY READ contentY WRITE setContentY NOTIFY contentYChanged)
Q_PROPERTY(qreal horizontalVelocity READ horizontalVelocity NOTIFY horizontalVelocityChanged)
Q_PROPERTY(qreal verticalVelocity READ verticalVelocity NOTIFY verticalVelocityChanged)
- Q_PROPERTY(qreal reportedVelocitySmoothing READ reportedVelocitySmoothing WRITE setReportedVelocitySmoothing NOTIFY reportedVelocitySmoothingChanged)
Q_PROPERTY(bool overShoot READ overShoot WRITE setOverShoot NOTIFY overShootChanged)
Q_PROPERTY(qreal maximumFlickVelocity READ maximumFlickVelocity WRITE setMaximumFlickVelocity NOTIFY maximumFlickVelocityChanged)
@@ -98,17 +97,17 @@ public:
bool overShoot() const;
void setOverShoot(bool);
- qreal viewportWidth() const;
- void setViewportWidth(qreal);
+ qreal contentWidth() const;
+ void setContentWidth(qreal);
- qreal viewportHeight() const;
- void setViewportHeight(qreal);
+ qreal contentHeight() const;
+ void setContentHeight(qreal);
- qreal viewportX() const;
- void setViewportX(qreal pos);
+ qreal contentX() const;
+ void setContentX(qreal pos);
- qreal viewportY() const;
- void setViewportY(qreal pos);
+ qreal contentY() const;
+ void setContentY(qreal pos);
bool isMoving() const;
bool isFlicking() const;
@@ -116,9 +115,6 @@ public:
int pressDelay() const;
void setPressDelay(int delay);
- qreal reportedVelocitySmoothing() const;
- void setReportedVelocitySmoothing(qreal);
-
qreal maximumFlickVelocity() const;
void setMaximumFlickVelocity(qreal);
@@ -143,17 +139,16 @@ public:
void setFlickDirection(FlickDirection);
Q_SIGNALS:
- void viewportWidthChanged();
- void viewportHeightChanged();
- void positionXChanged();
- void positionYChanged();
+ void contentWidthChanged();
+ void contentHeightChanged();
+ void contentXChanged();
+ void contentYChanged();
void movingChanged();
void flickingChanged();
void movementStarted();
void movementEnded();
void flickStarted();
void flickEnded();
- void reportedVelocitySmoothingChanged(int);
void horizontalVelocityChanged();
void verticalVelocityChanged();
void isAtBoundaryChanged();
diff --git a/src/declarative/graphicsitems/qdeclarativeflickable_p_p.h b/src/declarative/graphicsitems/qdeclarativeflickable_p_p.h
index dc3a8a2..ad7a04d 100644
--- a/src/declarative/graphicsitems/qdeclarativeflickable_p_p.h
+++ b/src/declarative/graphicsitems/qdeclarativeflickable_p_p.h
@@ -85,6 +85,8 @@ public:
void setRoundedViewportX(qreal x);
void setRoundedViewportY(qreal y);
+ qreal overShootDistance(qreal velocity, qreal size);
+
public:
QDeclarativeItem *viewport;
QDeclarativeTimeLineValueProxy<QDeclarativeFlickablePrivate> _moveX;
@@ -132,8 +134,10 @@ public:
Velocity(QDeclarativeFlickablePrivate *p)
: parent(p) {}
virtual void setValue(qreal v) {
- QDeclarativeTimeLineValue::setValue(v);
- parent->updateVelocity();
+ if (v != value()) {
+ QDeclarativeTimeLineValue::setValue(v);
+ parent->updateVelocity();
+ }
}
QDeclarativeFlickablePrivate *parent;
};
diff --git a/src/declarative/graphicsitems/qdeclarativegridview.cpp b/src/declarative/graphicsitems/qdeclarativegridview.cpp
index b378db2..b43b30b 100644
--- a/src/declarative/graphicsitems/qdeclarativegridview.cpp
+++ b/src/declarative/graphicsitems/qdeclarativegridview.cpp
@@ -133,14 +133,14 @@ public:
qreal position() const {
Q_Q(const QDeclarativeGridView);
- return flow == QDeclarativeGridView::LeftToRight ? q->viewportY() : q->viewportX();
+ return flow == QDeclarativeGridView::LeftToRight ? q->contentY() : q->contentX();
}
void setPosition(qreal pos) {
Q_Q(QDeclarativeGridView);
if (flow == QDeclarativeGridView::LeftToRight)
- q->setViewportY(pos);
+ q->setContentY(pos);
else
- q->setViewportX(pos);
+ q->setContentX(pos);
}
int size() const {
Q_Q(const QDeclarativeGridView);
@@ -315,9 +315,9 @@ FxGridItem *QDeclarativeGridViewPrivate::createItem(int modelIndex)
if (QDeclarativeItem *item = model->item(modelIndex, false)) {
listItem = new FxGridItem(item, q);
listItem->index = modelIndex;
+ listItem->item->setZValue(1);
// complete
model->completeItem();
- listItem->item->setZValue(1);
listItem->item->setParent(q->viewport());
unrequestedItems.remove(listItem->item);
}
@@ -458,9 +458,9 @@ void QDeclarativeGridViewPrivate::refill(qreal from, qreal to, bool doBuffer)
}
if (changed) {
if (flow == QDeclarativeGridView::LeftToRight)
- q->setViewportHeight(endPosition() - startPosition());
+ q->setContentHeight(endPosition() - startPosition());
else
- q->setViewportWidth(endPosition() - startPosition());
+ q->setContentWidth(endPosition() - startPosition());
} else if (!doBuffer && buffer && bufferMode != NoBuffer) {
refill(from, to, true);
}
@@ -473,9 +473,9 @@ void QDeclarativeGridViewPrivate::updateGrid()
columns = (int)qMax((flow == QDeclarativeGridView::LeftToRight ? q->width() : q->height()) / colSize(), qreal(1.));
if (isValid()) {
if (flow == QDeclarativeGridView::LeftToRight)
- q->setViewportHeight(endPosition() - startPosition());
+ q->setContentHeight(endPosition() - startPosition());
else
- q->setViewportWidth(endPosition() - startPosition());
+ q->setContentWidth(endPosition() - startPosition());
}
}
@@ -516,10 +516,10 @@ void QDeclarativeGridViewPrivate::layout(bool removed)
updateHighlight();
moveReason = Other;
if (flow == QDeclarativeGridView::LeftToRight) {
- q->setViewportHeight(endPosition() - startPosition());
+ q->setContentHeight(endPosition() - startPosition());
fixupY();
} else {
- q->setViewportWidth(endPosition() - startPosition());
+ q->setContentWidth(endPosition() - startPosition());
fixupX();
}
updateUnrequestedPositions();
@@ -607,11 +607,11 @@ void QDeclarativeGridViewPrivate::createHighlight()
item->setParent(q->viewport());
highlight = new FxGridItem(item, q);
highlightXAnimator = new QDeclarativeEaseFollow(q);
- highlightXAnimator->setTarget(QDeclarativeMetaProperty(highlight->item, QLatin1String("x")));
+ highlightXAnimator->setTarget(QDeclarativeProperty(highlight->item, QLatin1String("x")));
highlightXAnimator->setDuration(150);
highlightXAnimator->setEnabled(autoHighlight);
highlightYAnimator = new QDeclarativeEaseFollow(q);
- highlightYAnimator->setTarget(QDeclarativeMetaProperty(highlight->item, QLatin1String("y")));
+ highlightYAnimator->setTarget(QDeclarativeProperty(highlight->item, QLatin1String("y")));
highlightYAnimator->setDuration(150);
highlightYAnimator->setEnabled(autoHighlight);
changed = true;
@@ -675,6 +675,7 @@ void QDeclarativeGridViewPrivate::updateCurrent(int modelIndex)
/*!
\qmlclass GridView QDeclarativeGridView
+ \since 4.7
\inherits Flickable
\brief The GridView item provides a grid view of items provided by a model.
@@ -1028,10 +1029,10 @@ void QDeclarativeGridView::setFlow(Flow flow)
if (d->flow != flow) {
d->flow = flow;
if (d->flow == LeftToRight) {
- setViewportWidth(-1);
+ setContentWidth(-1);
setFlickDirection(QDeclarativeFlickable::VerticalFlick);
} else {
- setViewportHeight(-1);
+ setContentHeight(-1);
setFlickDirection(QDeclarativeFlickable::HorizontalFlick);
}
d->clear();
diff --git a/src/declarative/graphicsitems/qdeclarativeimage.cpp b/src/declarative/graphicsitems/qdeclarativeimage.cpp
index 338b086..99ab053 100644
--- a/src/declarative/graphicsitems/qdeclarativeimage.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeimage.cpp
@@ -127,7 +127,7 @@ QT_BEGIN_NAMESPACE
QDeclarativeImage::QDeclarativeImage(QDeclarativeItem *parent)
: QDeclarativeImageBase(*(new QDeclarativeImagePrivate), parent)
{
- connect(this, SIGNAL(sourceChanged(QUrl)), this, SLOT(updatePaintedGeometry()));
+ connect(this, SIGNAL(pixmapChanged()), this, SLOT(updatePaintedGeometry()));
}
QDeclarativeImage::QDeclarativeImage(QDeclarativeImagePrivate &dd, QDeclarativeItem *parent)
@@ -139,12 +139,6 @@ QDeclarativeImage::~QDeclarativeImage()
{
}
-void QDeclarativeImage::setSource(const QUrl &url)
-{
- QDeclarativeImageBase::setSource(url);
- updatePaintedGeometry();
-}
-
/*!
\qmlproperty QPixmap Image::pixmap
@@ -268,10 +262,10 @@ void QDeclarativeImage::updatePaintedGeometry()
Q_D(QDeclarativeImage);
if (d->fillMode == PreserveAspectFit) {
- qreal widthScale = width() / qreal(d->pix.width());
- qreal heightScale = height() / qreal(d->pix.height());
if (!d->pix.width() || !d->pix.height())
return;
+ qreal widthScale = width() / qreal(d->pix.width());
+ qreal heightScale = height() / qreal(d->pix.height());
if (widthScale <= heightScale) {
d->paintedWidth = width();
d->paintedHeight = widthScale * qreal(d->pix.height());
diff --git a/src/declarative/graphicsitems/qdeclarativeimage_p.h b/src/declarative/graphicsitems/qdeclarativeimage_p.h
index 5b365e7..fb77ac9 100644
--- a/src/declarative/graphicsitems/qdeclarativeimage_p.h
+++ b/src/declarative/graphicsitems/qdeclarativeimage_p.h
@@ -76,7 +76,6 @@ public:
qreal paintedWidth() const;
qreal paintedHeight() const;
- void setSource(const QUrl &url);
void paint(QPainter *, const QStyleOptionGraphicsItem *, QWidget *);
Q_SIGNALS:
diff --git a/src/declarative/graphicsitems/qdeclarativeitem.cpp b/src/declarative/graphicsitems/qdeclarativeitem.cpp
index c282808..f48c761 100644
--- a/src/declarative/graphicsitems/qdeclarativeitem.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeitem.cpp
@@ -1730,8 +1730,12 @@ void QDeclarativeItem::geometryChanged(const QRectF &newGeometry,
if (d->_anchors)
d->_anchors->d_func()->updateMe();
- if (transformOrigin() != QDeclarativeItem::TopLeft)
- setTransformOriginPoint(d->computeTransformOrigin());
+ if (transformOrigin() != QDeclarativeItem::TopLeft
+ && (newGeometry.width() != oldGeometry.width() || newGeometry.height() != oldGeometry.height())) {
+ QPointF origin = d->computeTransformOrigin();
+ if (transformOriginPoint() != origin)
+ setTransformOriginPoint(origin);
+ }
if (newGeometry.x() != oldGeometry.x())
emit xChanged();
diff --git a/src/declarative/graphicsitems/qdeclarativeitem_p.h b/src/declarative/graphicsitems/qdeclarativeitem_p.h
index 81c5688..4b4917e 100644
--- a/src/declarative/graphicsitems/qdeclarativeitem_p.h
+++ b/src/declarative/graphicsitems/qdeclarativeitem_p.h
@@ -60,8 +60,8 @@
#include "qdeclarativeitemchangelistener_p.h"
#include <private/qpodvector_p.h>
-#include "../util/qdeclarativestate_p.h"
-#include "../util/qdeclarativenullablevalue_p_p.h"
+#include <private/qdeclarativestate_p.h>
+#include <private/qdeclarativenullablevalue_p_p.h>
#include <qdeclarative.h>
#include <qdeclarativecontext.h>
diff --git a/src/declarative/graphicsitems/qdeclarativelistview.cpp b/src/declarative/graphicsitems/qdeclarativelistview.cpp
index bd2f4fc..03303a0 100644
--- a/src/declarative/graphicsitems/qdeclarativelistview.cpp
+++ b/src/declarative/graphicsitems/qdeclarativelistview.cpp
@@ -203,14 +203,14 @@ public:
qreal position() const {
Q_Q(const QDeclarativeListView);
- return orient == QDeclarativeListView::Vertical ? q->viewportY() : q->viewportX();
+ return orient == QDeclarativeListView::Vertical ? q->contentY() : q->contentX();
}
void setPosition(qreal pos) {
Q_Q(QDeclarativeListView);
if (orient == QDeclarativeListView::Vertical)
- q->setViewportY(pos);
+ q->setContentY(pos);
else
- q->setViewportX(pos);
+ q->setContentX(pos);
}
qreal size() const {
Q_Q(const QDeclarativeListView);
@@ -382,9 +382,9 @@ public:
void updateViewport() {
Q_Q(QDeclarativeListView);
if (orient == QDeclarativeListView::Vertical) {
- q->setViewportHeight(endPosition() - startPosition() + 1);
+ q->setContentHeight(endPosition() - startPosition() + 1);
} else {
- q->setViewportWidth(endPosition() - startPosition() + 1);
+ q->setContentWidth(endPosition() - startPosition() + 1);
}
}
@@ -530,9 +530,9 @@ FxListItem *QDeclarativeListViewPrivate::createItem(int modelIndex)
listItem->attached->m_prevSection = sectionAt(modelIndex-1);
}
}
+ listItem->item->setZValue(1);
// complete
model->completeItem();
- listItem->item->setZValue(1);
listItem->item->setParent(q->viewport());
QDeclarativeItemPrivate *itemPrivate = static_cast<QDeclarativeItemPrivate*>(QGraphicsItemPrivate::get(item));
itemPrivate->addItemChangeListener(this, QDeclarativeItemPrivate::Geometry);
@@ -804,13 +804,13 @@ void QDeclarativeListViewPrivate::createHighlight()
highlight->item->setWidth(currentItem->item->width());
const QLatin1String posProp(orient == QDeclarativeListView::Vertical ? "y" : "x");
highlightPosAnimator = new QDeclarativeEaseFollow(q);
- highlightPosAnimator->setTarget(QDeclarativeMetaProperty(highlight->item, posProp));
+ highlightPosAnimator->setTarget(QDeclarativeProperty(highlight->item, posProp));
highlightPosAnimator->setVelocity(highlightMoveSpeed);
highlightPosAnimator->setEnabled(autoHighlight);
const QLatin1String sizeProp(orient == QDeclarativeListView::Vertical ? "height" : "width");
highlightSizeAnimator = new QDeclarativeEaseFollow(q);
highlightSizeAnimator->setVelocity(highlightResizeSpeed);
- highlightSizeAnimator->setTarget(QDeclarativeMetaProperty(highlight->item, sizeProp));
+ highlightSizeAnimator->setTarget(QDeclarativeProperty(highlight->item, sizeProp));
highlightSizeAnimator->setEnabled(autoHighlight);
changed = true;
}
@@ -1073,7 +1073,7 @@ void QDeclarativeListViewPrivate::fixupY()
qreal pos = currentItem->position() - highlightRangeStart;
timeline.reset(_moveY);
if (fixupDuration)
- timeline.move(_moveY, -pos, QEasingCurve(QEasingCurve::InOutQuad), fixupDuration);
+ timeline.move(_moveY, -pos, QEasingCurve(QEasingCurve::InOutQuad), fixupDuration/2);
else
_moveY.setValue(-pos);
vTime = timeline.time();
@@ -1085,7 +1085,7 @@ void QDeclarativeListViewPrivate::fixupY()
if (dist > 0) {
timeline.reset(_moveY);
if (fixupDuration)
- timeline.move(_moveY, -pos, QEasingCurve(QEasingCurve::InOutQuad), fixupDuration);
+ timeline.move(_moveY, -pos, QEasingCurve(QEasingCurve::InOutQuad), fixupDuration/2);
else
_moveY.setValue(-pos);
vTime = timeline.time();
@@ -1155,7 +1155,7 @@ void QDeclarativeListViewPrivate::flickX(qreal velocity)
if (FxListItem *item = firstVisibleItem())
maxDistance = qAbs(item->position() + _moveX.value());
} else if (_moveX.value() < minX) {
- maxDistance = qAbs(minX -_moveX.value() + (overShoot?30:0));
+ maxDistance = qAbs(minX -_moveX.value() + (overShoot?overShootDistance(velocity, q->width()):0));
}
if (snapMode != QDeclarativeListView::SnapToItem && highlightRange != QDeclarativeListView::StrictlyEnforceRange)
flickTargetX = minX;
@@ -1164,7 +1164,7 @@ void QDeclarativeListViewPrivate::flickX(qreal velocity)
if (FxListItem *item = nextVisibleItem())
maxDistance = qAbs(item->position() + _moveX.value());
} else if (_moveX.value() > maxX) {
- maxDistance = qAbs(maxX - _moveX.value()) + (overShoot?30:0);
+ maxDistance = qAbs(maxX - _moveX.value()) + (overShoot?overShootDistance(velocity, q->width()):0);
}
if (snapMode != QDeclarativeListView::SnapToItem && highlightRange != QDeclarativeListView::StrictlyEnforceRange)
flickTargetX = maxX;
@@ -1196,7 +1196,7 @@ void QDeclarativeListViewPrivate::flickX(qreal velocity)
overshootDist = 0.0;
} else {
flickTargetX = velocity > 0 ? minX : maxX;
- overshootDist = overShoot ? 30 : 0;
+ overshootDist = overShoot ? overShootDistance(v, q->width()) : 0;
}
timeline.reset(_moveX);
timeline.accel(_moveX, v, accel, maxDistance + overshootDist);
@@ -1253,7 +1253,7 @@ void QDeclarativeListViewPrivate::flickY(qreal velocity)
if (FxListItem *item = firstVisibleItem())
maxDistance = qAbs(item->position() + _moveY.value());
} else if (_moveY.value() < minY) {
- maxDistance = qAbs(minY -_moveY.value() + (overShoot?30:0));
+ maxDistance = qAbs(minY -_moveY.value() + (overShoot?overShootDistance(velocity, q->height()):0));
}
if (snapMode != QDeclarativeListView::SnapToItem && highlightRange != QDeclarativeListView::StrictlyEnforceRange)
flickTargetY = minY;
@@ -1262,7 +1262,7 @@ void QDeclarativeListViewPrivate::flickY(qreal velocity)
if (FxListItem *item = nextVisibleItem())
maxDistance = qAbs(item->position() + _moveY.value());
} else if (_moveY.value() > maxY) {
- maxDistance = qAbs(maxY - _moveY.value()) + (overShoot?30:0);
+ maxDistance = qAbs(maxY - _moveY.value()) + (overShoot?overShootDistance(velocity, q->height()):0);
}
if (snapMode != QDeclarativeListView::SnapToItem && highlightRange != QDeclarativeListView::StrictlyEnforceRange)
flickTargetY = maxY;
@@ -1294,7 +1294,7 @@ void QDeclarativeListViewPrivate::flickY(qreal velocity)
overshootDist = 0.0;
} else {
flickTargetY = velocity > 0 ? minY : maxY;
- overshootDist = overShoot ? 30 : 0;
+ overshootDist = overShoot ? overShootDistance(v, q->height()) : 0;
}
timeline.reset(_moveY);
timeline.accel(_moveY, v, accel, maxDistance + overshootDist);
@@ -1819,10 +1819,10 @@ void QDeclarativeListView::setOrientation(QDeclarativeListView::Orientation orie
if (d->orient != orientation) {
d->orient = orientation;
if (d->orient == QDeclarativeListView::Vertical) {
- setViewportWidth(-1);
+ setContentWidth(-1);
setFlickDirection(VerticalFlick);
} else {
- setViewportHeight(-1);
+ setContentHeight(-1);
setFlickDirection(HorizontalFlick);
}
d->clear();
@@ -1980,6 +1980,12 @@ void QDeclarativeListView::setHighlightResizeSpeed(qreal speed)
visible item at the time the mouse button is released. This mode is particularly
useful for moving one page at a time.
\endlist
+
+ snapMode does not affect the currentIndex. To update the
+ currentIndex as the list is moved set \e highlightRangeMode
+ to \e StrictlyEnforceRange.
+
+ \sa highlightRangeMode
*/
QDeclarativeListView::SnapMode QDeclarativeListView::snapMode() const
{
diff --git a/src/declarative/graphicsitems/qdeclarativeparticles.cpp b/src/declarative/graphicsitems/qdeclarativeparticles.cpp
index 3c07798..1a58d3f 100644
--- a/src/declarative/graphicsitems/qdeclarativeparticles.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeparticles.cpp
@@ -1260,7 +1260,7 @@ void QDeclarativeParticlesPainter::paint(QPainter *p, const QStyleOptionGraphics
const int myX = x() + parentItem()->x();
const int myY = y() + parentItem()->y();
- QVarLengthArray<QDrawPixmaps::Data, 256> pixmapData;
+ QVarLengthArray<QPainter::Fragment, 256> pixmapData;
pixmapData.resize(d->particles.count());
const QRectF sourceRect = d->image.rect();
@@ -1268,16 +1268,20 @@ void QDeclarativeParticlesPainter::paint(QPainter *p, const QStyleOptionGraphics
qreal halfPHeight = sourceRect.height()/2.;
for (int i = 0; i < d->particles.count(); ++i) {
const QDeclarativeParticle &particle = d->particles.at(i);
- pixmapData[i].point = QPointF(particle.x - myX + halfPWidth, particle.y - myY + halfPHeight);
+ pixmapData[i].x = particle.x - myX + halfPWidth;
+ pixmapData[i].y = particle.y - myY + halfPHeight;
pixmapData[i].opacity = particle.opacity;
//these never change
pixmapData[i].rotation = 0;
pixmapData[i].scaleX = 1;
pixmapData[i].scaleY = 1;
- pixmapData[i].source = sourceRect;
+ pixmapData[i].sourceLeft = sourceRect.left();
+ pixmapData[i].sourceTop = sourceRect.top();
+ pixmapData[i].width = sourceRect.width();
+ pixmapData[i].height = sourceRect.height();
}
- qDrawPixmaps(p, pixmapData.data(), d->particles.count(), d->image);
+ p->drawPixmapFragments(pixmapData.data(), d->particles.count(), d->image);
}
void QDeclarativeParticles::componentComplete()
diff --git a/src/declarative/graphicsitems/qdeclarativepathview.cpp b/src/declarative/graphicsitems/qdeclarativepathview.cpp
index c131f4c..f1b0213 100644
--- a/src/declarative/graphicsitems/qdeclarativepathview.cpp
+++ b/src/declarative/graphicsitems/qdeclarativepathview.cpp
@@ -111,7 +111,7 @@ QDeclarativeItem *QDeclarativePathViewPrivate::getItem(int modelIndex)
{
Q_Q(QDeclarativePathView);
requestedIndex = modelIndex;
- QDeclarativeItem *item = model->item(modelIndex);
+ QDeclarativeItem *item = model->item(modelIndex, false);
if (item) {
if (QObject *obj = QDeclarativePathView::qmlAttachedProperties(item))
static_cast<QDeclarativePathViewAttached *>(obj)->setOnPath(true);
@@ -655,6 +655,7 @@ void QDeclarativePathViewPrivate::regenerate()
}
items.append(item);
item->setZValue(i);
+ model->completeItem();
if (currentIndex == index)
item->setFocus(true);
}
@@ -715,6 +716,7 @@ void QDeclarativePathView::refill()
int index = (d->firstIndex + d->items.count())%d->model->count();
QDeclarativeItem *item = d->getItem(index);
item->setZValue(wrapIndex);
+ d->model->completeItem();
if (d->currentIndex == index)
item->setFocus(true);
d->items << item;
@@ -731,6 +733,7 @@ void QDeclarativePathView::refill()
d->firstIndex = d->model->count() - 1;
QDeclarativeItem *item = d->getItem(d->firstIndex);
item->setZValue(d->firstIndex);
+ d->model->completeItem();
if (d->currentIndex == d->firstIndex)
item->setFocus(true);
d->items.prepend(item);
@@ -757,6 +760,7 @@ void QDeclarativePathView::itemsInserted(int modelIndex, int count)
for (int i = 0; i < count; ++i) {
QDeclarativeItem *item = d->getItem(modelIndex + i);
item->setZValue(modelIndex + i);
+ d->model->completeItem();
d->items.insert(modelIndex + i, item);
}
refill();
diff --git a/src/declarative/graphicsitems/qdeclarativepositioners_p.h b/src/declarative/graphicsitems/qdeclarativepositioners_p.h
index ff6fc4b..f38847c 100644
--- a/src/declarative/graphicsitems/qdeclarativepositioners_p.h
+++ b/src/declarative/graphicsitems/qdeclarativepositioners_p.h
@@ -44,7 +44,7 @@
#include "qdeclarativeitem.h"
-#include "../util/qdeclarativestate_p.h"
+#include <private/qdeclarativestate_p.h>
#include <private/qpodvector_p.h>
#include <QtCore/QObject>
diff --git a/src/declarative/graphicsitems/qdeclarativescalegrid_p_p.h b/src/declarative/graphicsitems/qdeclarativescalegrid_p_p.h
index 92b3f91..fbf9040 100644
--- a/src/declarative/graphicsitems/qdeclarativescalegrid_p_p.h
+++ b/src/declarative/graphicsitems/qdeclarativescalegrid_p_p.h
@@ -44,7 +44,7 @@
#include "qdeclarativeborderimage_p.h"
-#include "../util/qdeclarativepixmapcache_p.h"
+#include <private/qdeclarativepixmapcache_p.h>
#include <qdeclarative.h>
#include <QtCore/QString>
diff --git a/src/declarative/graphicsitems/qdeclarativetextinput.cpp b/src/declarative/graphicsitems/qdeclarativetextinput.cpp
index 9919904..3382628 100644
--- a/src/declarative/graphicsitems/qdeclarativetextinput.cpp
+++ b/src/declarative/graphicsitems/qdeclarativetextinput.cpp
@@ -704,6 +704,8 @@ bool QDeclarativeTextInput::event(QEvent* ev)
break;
default:
handled = d->control->processEvent(ev);
+ if (ev->type() == QEvent::InputMethod)
+ updateSize();
}
if(!handled)
return QDeclarativePaintedItem::event(ev);
diff --git a/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp b/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp
index 2402648..cd72ef9 100644
--- a/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp
+++ b/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp
@@ -917,7 +917,7 @@ QDeclarativeVisualDataModel::ReleaseFlags QDeclarativeVisualDataModel::release(Q
if (inPackage) {
emit destroyingPackage(qobject_cast<QDeclarativePackage*>(obj));
} else {
- item->setVisible(false);
+ item->setOpacity(0.0);
static_cast<QGraphicsItem*>(item)->setParentItem(0);
}
stat |= Destroyed;
diff --git a/src/declarative/graphicsitems/qdeclarativewebview.cpp b/src/declarative/graphicsitems/qdeclarativewebview.cpp
index 61b5b56..a2b16ba 100644
--- a/src/declarative/graphicsitems/qdeclarativewebview.cpp
+++ b/src/declarative/graphicsitems/qdeclarativewebview.cpp
@@ -177,6 +177,8 @@ void QDeclarativeWebView::init()
{
Q_D(QDeclarativeWebView);
+ QWebSettings::enablePersistentStorage();
+
setAcceptHoverEvents(true);
setAcceptedMouseButtons(Qt::LeftButton);
setFlag(QGraphicsItem::ItemHasNoContents, false);
@@ -955,6 +957,7 @@ void QDeclarativeWebView::setPage(QWebPage *page)
connect(d->page,SIGNAL(repaintRequested(QRect)),this,SLOT(paintPage(QRect)));
connect(d->page->mainFrame(),SIGNAL(urlChanged(QUrl)),this,SLOT(pageUrlChanged()));
connect(d->page->mainFrame(), SIGNAL(titleChanged(QString)), this, SIGNAL(titleChanged(QString)));
+ connect(d->page->mainFrame(), SIGNAL(titleChanged(QString)), this, SIGNAL(iconChanged()));
connect(d->page->mainFrame(), SIGNAL(iconChanged()), this, SIGNAL(iconChanged()));
connect(d->page->mainFrame(), SIGNAL(contentsSizeChanged(QSize)), this, SLOT(noteContentsSizeChanged(QSize)));
connect(d->page->mainFrame(), SIGNAL(initialLayoutCompleted()), this, SLOT(initialLayout()));
diff --git a/src/declarative/qml/parser/qdeclarativejs.g b/src/declarative/qml/parser/qdeclarativejs.g
index e1cb5a5..7cf81b2 100644
--- a/src/declarative/qml/parser/qdeclarativejs.g
+++ b/src/declarative/qml/parser/qdeclarativejs.g
@@ -65,6 +65,7 @@
%token T_PUBLIC "public"
%token T_IMPORT "import"
%token T_AS "as"
+%token T_ON "on"
--- feed tokens
%token T_FEED_UI_PROGRAM
@@ -773,6 +774,17 @@ case $rule_number: {
} break;
./
+UiObjectMember: UiQualifiedId T_ON UiQualifiedId UiObjectInitializer ;
+/.
+case $rule_number: {
+ AST::UiObjectBinding *node = makeAstNode<AST::UiObjectBinding> (driver->nodePool(),
+ sym(3).UiQualifiedId, sym(1).UiQualifiedId, sym(4).UiObjectInitializer);
+ node->colonToken = loc(2);
+ node->hasOnToken = true;
+ sym(1).Node = node;
+} break;
+./
+
UiObjectMember: UiQualifiedId T_COLON Block ;
/.case $rule_number:./
@@ -870,8 +882,8 @@ case $rule_number: {
} break;
./
-UiObjectMember: T_PROPERTY T_IDENTIFIER T_LT UiPropertyType T_GT T_IDENTIFIER T_AUTOMATIC_SEMICOLON ;
-UiObjectMember: T_PROPERTY T_IDENTIFIER T_LT UiPropertyType T_GT T_IDENTIFIER T_SEMICOLON ;
+UiObjectMember: T_PROPERTY T_IDENTIFIER T_LT UiPropertyType T_GT JsIdentifier T_AUTOMATIC_SEMICOLON ;
+UiObjectMember: T_PROPERTY T_IDENTIFIER T_LT UiPropertyType T_GT JsIdentifier T_SEMICOLON ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(4).sval, sym(6).sval);
@@ -885,8 +897,8 @@ case $rule_number: {
} break;
./
-UiObjectMember: T_PROPERTY UiPropertyType T_IDENTIFIER T_AUTOMATIC_SEMICOLON ;
-UiObjectMember: T_PROPERTY UiPropertyType T_IDENTIFIER T_SEMICOLON ;
+UiObjectMember: T_PROPERTY UiPropertyType JsIdentifier T_AUTOMATIC_SEMICOLON ;
+UiObjectMember: T_PROPERTY UiPropertyType JsIdentifier T_SEMICOLON ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval);
@@ -898,8 +910,8 @@ case $rule_number: {
} break;
./
-UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType T_IDENTIFIER T_AUTOMATIC_SEMICOLON ;
-UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType T_IDENTIFIER T_SEMICOLON ;
+UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType JsIdentifier T_AUTOMATIC_SEMICOLON ;
+UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType JsIdentifier T_SEMICOLON ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval);
@@ -913,8 +925,8 @@ case $rule_number: {
} break;
./
-UiObjectMember: T_PROPERTY UiPropertyType T_IDENTIFIER T_COLON Expression T_AUTOMATIC_SEMICOLON ;
-UiObjectMember: T_PROPERTY UiPropertyType T_IDENTIFIER T_COLON Expression T_SEMICOLON ;
+UiObjectMember: T_PROPERTY UiPropertyType JsIdentifier T_COLON Expression T_AUTOMATIC_SEMICOLON ;
+UiObjectMember: T_PROPERTY UiPropertyType JsIdentifier T_COLON Expression T_SEMICOLON ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval,
@@ -928,8 +940,8 @@ case $rule_number: {
} break;
./
-UiObjectMember: T_READONLY T_PROPERTY UiPropertyType T_IDENTIFIER T_COLON Expression T_AUTOMATIC_SEMICOLON ;
-UiObjectMember: T_READONLY T_PROPERTY UiPropertyType T_IDENTIFIER T_COLON Expression T_SEMICOLON ;
+UiObjectMember: T_READONLY T_PROPERTY UiPropertyType JsIdentifier T_COLON Expression T_AUTOMATIC_SEMICOLON ;
+UiObjectMember: T_READONLY T_PROPERTY UiPropertyType JsIdentifier T_COLON Expression T_SEMICOLON ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval,
@@ -945,8 +957,8 @@ case $rule_number: {
} break;
./
-UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType T_IDENTIFIER T_COLON Expression T_AUTOMATIC_SEMICOLON ;
-UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType T_IDENTIFIER T_COLON Expression T_SEMICOLON ;
+UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType JsIdentifier T_COLON Expression T_AUTOMATIC_SEMICOLON ;
+UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType JsIdentifier T_COLON Expression T_SEMICOLON ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval,
@@ -1005,6 +1017,15 @@ case $rule_number: {
}
./
+JsIdentifier: T_ON ;
+/.
+case $rule_number: {
+ QString s = QLatin1String(QDeclarativeJSGrammar::spell[T_READONLY]);
+ sym(1).sval = driver->intern(s.constData(), s.length());
+ break;
+}
+./
+
--------------------------------------------------------------------------------------------------------
-- Expressions
--------------------------------------------------------------------------------------------------------
diff --git a/src/declarative/qml/parser/qdeclarativejsast_p.h b/src/declarative/qml/parser/qdeclarativejsast_p.h
index 0a83fe2..c1945ce 100644
--- a/src/declarative/qml/parser/qdeclarativejsast_p.h
+++ b/src/declarative/qml/parser/qdeclarativejsast_p.h
@@ -2599,11 +2599,17 @@ public:
UiObjectInitializer *initializer)
: qualifiedId(qualifiedId),
qualifiedTypeNameId(qualifiedTypeNameId),
- initializer(initializer)
+ initializer(initializer),
+ hasOnToken(false)
{ kind = K; }
virtual SourceLocation firstSourceLocation() const
- { return qualifiedId->identifierToken; }
+ {
+ if (hasOnToken && qualifiedTypeNameId)
+ return qualifiedTypeNameId->identifierToken;
+
+ return qualifiedId->identifierToken;
+ }
virtual SourceLocation lastSourceLocation() const
{ return initializer->rbraceToken; }
@@ -2615,6 +2621,7 @@ public:
UiQualifiedId *qualifiedTypeNameId;
UiObjectInitializer *initializer;
SourceLocation colonToken;
+ bool hasOnToken;
};
class QML_PARSER_EXPORT UiScriptBinding: public UiObjectMember
diff --git a/src/declarative/qml/parser/qdeclarativejsgrammar.cpp b/src/declarative/qml/parser/qdeclarativejsgrammar.cpp
index aadb432..0677bc5 100644
--- a/src/declarative/qml/parser/qdeclarativejsgrammar.cpp
+++ b/src/declarative/qml/parser/qdeclarativejsgrammar.cpp
@@ -54,581 +54,608 @@ const char *const QDeclarativeJSGrammar::spell [] = {
")", ";", 0, "*", "*=", "string literal", "property", "signal", "readonly", "switch",
"this", "throw", "~", "try", "typeof", "var", "void", "while", "with", "^",
"^=", "null", "true", "false", "const", "debugger", "reserved word", "multiline string literal", "comment", "public",
- "import", "as", 0, 0, 0, 0, 0, 0, 0, 0};
+ "import", "as", "on", 0, 0, 0, 0, 0, 0, 0,
+ 0};
const short QDeclarativeJSGrammar::lhs [] = {
- 100, 100, 100, 100, 100, 100, 101, 107, 107, 110,
- 110, 112, 111, 111, 111, 111, 111, 111, 111, 111,
- 114, 109, 108, 117, 117, 118, 118, 119, 119, 116,
- 105, 105, 105, 105, 105, 105, 105, 125, 125, 125,
- 126, 126, 127, 127, 105, 105, 105, 105, 105, 105,
- 105, 105, 105, 105, 105, 105, 105, 105, 105, 105,
- 105, 105, 115, 115, 115, 115, 130, 130, 130, 130,
- 130, 130, 130, 130, 130, 130, 130, 130, 130, 130,
- 130, 130, 130, 130, 120, 132, 132, 132, 132, 131,
- 131, 134, 134, 136, 136, 136, 136, 136, 136, 137,
- 137, 137, 137, 137, 137, 137, 137, 137, 137, 137,
- 137, 137, 137, 137, 137, 137, 137, 137, 137, 137,
- 137, 137, 137, 137, 137, 137, 137, 137, 137, 137,
- 138, 138, 113, 113, 113, 113, 113, 141, 141, 142,
- 142, 142, 142, 140, 140, 143, 143, 144, 144, 145,
- 145, 145, 146, 146, 146, 146, 146, 146, 146, 146,
- 146, 146, 147, 147, 147, 147, 148, 148, 148, 149,
- 149, 149, 149, 150, 150, 150, 150, 150, 150, 150,
- 151, 151, 151, 151, 151, 151, 152, 152, 152, 152,
- 152, 153, 153, 153, 153, 153, 154, 154, 155, 155,
+ 101, 101, 101, 101, 101, 101, 102, 108, 108, 111,
+ 111, 113, 112, 112, 112, 112, 112, 112, 112, 112,
+ 115, 110, 109, 118, 118, 119, 119, 120, 120, 117,
+ 106, 106, 106, 106, 106, 106, 106, 106, 126, 126,
+ 126, 127, 127, 128, 128, 106, 106, 106, 106, 106,
+ 106, 106, 106, 106, 106, 106, 106, 106, 106, 106,
+ 106, 106, 106, 116, 116, 116, 116, 116, 131, 131,
+ 131, 131, 131, 131, 131, 131, 131, 131, 131, 131,
+ 131, 131, 131, 131, 131, 131, 121, 133, 133, 133,
+ 133, 132, 132, 135, 135, 137, 137, 137, 137, 137,
+ 137, 138, 138, 138, 138, 138, 138, 138, 138, 138,
+ 138, 138, 138, 138, 138, 138, 138, 138, 138, 138,
+ 138, 138, 138, 138, 138, 138, 138, 138, 138, 138,
+ 138, 138, 139, 139, 114, 114, 114, 114, 114, 142,
+ 142, 143, 143, 143, 143, 141, 141, 144, 144, 145,
+ 145, 146, 146, 146, 147, 147, 147, 147, 147, 147,
+ 147, 147, 147, 147, 148, 148, 148, 148, 149, 149,
+ 149, 150, 150, 150, 150, 151, 151, 151, 151, 151,
+ 151, 151, 152, 152, 152, 152, 152, 152, 153, 153,
+ 153, 153, 153, 154, 154, 154, 154, 154, 155, 155,
156, 156, 157, 157, 158, 158, 159, 159, 160, 160,
161, 161, 162, 162, 163, 163, 164, 164, 165, 165,
- 135, 135, 166, 166, 167, 167, 167, 167, 167, 167,
- 167, 167, 167, 167, 167, 167, 103, 103, 168, 168,
- 169, 169, 170, 170, 102, 102, 102, 102, 102, 102,
- 102, 102, 102, 102, 102, 102, 102, 102, 102, 121,
- 182, 182, 181, 181, 129, 129, 183, 183, 184, 184,
- 186, 186, 185, 187, 190, 188, 188, 191, 189, 189,
- 122, 123, 123, 124, 124, 171, 171, 171, 171, 171,
- 171, 171, 172, 172, 172, 172, 173, 173, 173, 173,
- 174, 174, 175, 177, 192, 192, 195, 195, 193, 193,
- 196, 194, 176, 176, 176, 178, 178, 179, 179, 179,
- 197, 198, 180, 180, 128, 139, 202, 202, 199, 199,
- 200, 200, 203, 106, 204, 204, 104, 104, 201, 201,
- 133, 133, 205};
+ 166, 166, 136, 136, 167, 167, 168, 168, 168, 168,
+ 168, 168, 168, 168, 168, 168, 168, 168, 104, 104,
+ 169, 169, 170, 170, 171, 171, 103, 103, 103, 103,
+ 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
+ 103, 122, 183, 183, 182, 182, 130, 130, 184, 184,
+ 185, 185, 187, 187, 186, 188, 191, 189, 189, 192,
+ 190, 190, 123, 124, 124, 125, 125, 172, 172, 172,
+ 172, 172, 172, 172, 173, 173, 173, 173, 174, 174,
+ 174, 174, 175, 175, 176, 178, 193, 193, 196, 196,
+ 194, 194, 197, 195, 177, 177, 177, 179, 179, 180,
+ 180, 180, 198, 199, 181, 181, 129, 140, 203, 203,
+ 200, 200, 201, 201, 204, 107, 205, 205, 105, 105,
+ 202, 202, 134, 134, 206};
const short QDeclarativeJSGrammar::rhs [] = {
2, 2, 2, 2, 2, 2, 2, 1, 1, 1,
2, 1, 2, 2, 3, 3, 5, 5, 4, 4,
2, 0, 1, 1, 2, 1, 3, 2, 3, 2,
- 1, 5, 4, 3, 3, 3, 3, 1, 1, 1,
- 0, 1, 2, 4, 6, 6, 3, 3, 7, 7,
- 4, 4, 5, 5, 6, 6, 7, 7, 7, 7,
+ 1, 5, 4, 4, 3, 3, 3, 3, 1, 1,
+ 1, 0, 1, 2, 4, 6, 6, 3, 3, 7,
+ 7, 4, 4, 5, 5, 6, 6, 7, 7, 7,
+ 7, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
+ 3, 4, 5, 3, 4, 3, 1, 1, 2, 3,
+ 4, 1, 2, 3, 5, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 2, 3, 3, 4,
- 5, 3, 4, 3, 1, 1, 2, 3, 4, 1,
- 2, 3, 5, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 4, 3, 5, 1, 2, 4,
- 4, 4, 3, 0, 1, 1, 3, 1, 1, 1,
- 2, 2, 1, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 1, 3, 3, 3, 1, 3, 3, 1,
- 3, 3, 3, 1, 3, 3, 3, 3, 3, 3,
- 1, 3, 3, 3, 3, 3, 1, 3, 3, 3,
- 3, 1, 3, 3, 3, 3, 1, 3, 1, 3,
+ 1, 1, 1, 1, 1, 1, 4, 3, 5, 1,
+ 2, 4, 4, 4, 3, 0, 1, 1, 3, 1,
+ 1, 1, 2, 2, 1, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 1, 3, 3, 3, 1, 3,
+ 3, 1, 3, 3, 3, 1, 3, 3, 3, 3,
+ 3, 3, 1, 3, 3, 3, 3, 3, 1, 3,
+ 3, 3, 3, 1, 3, 3, 3, 3, 1, 3,
1, 3, 1, 3, 1, 3, 1, 3, 1, 3,
- 1, 3, 1, 3, 1, 3, 1, 5, 1, 5,
- 1, 3, 1, 3, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 3, 0, 1,
- 1, 3, 0, 1, 1, 1, 1, 1, 1, 1,
+ 1, 3, 1, 3, 1, 3, 1, 3, 1, 5,
+ 1, 5, 1, 3, 1, 3, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 3,
- 1, 2, 0, 1, 3, 3, 1, 1, 1, 3,
- 1, 3, 2, 2, 2, 0, 1, 2, 0, 1,
- 1, 2, 2, 7, 5, 7, 7, 5, 9, 10,
- 7, 8, 2, 2, 3, 3, 2, 2, 3, 3,
- 3, 3, 5, 5, 3, 5, 1, 2, 0, 1,
- 4, 3, 3, 3, 3, 3, 3, 3, 3, 4,
- 5, 2, 2, 2, 8, 8, 1, 3, 0, 1,
- 0, 1, 1, 1, 1, 2, 1, 1, 0, 1,
- 0, 1, 2};
+ 0, 1, 1, 3, 0, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 3, 1, 2, 0, 1, 3, 3, 1, 1,
+ 1, 3, 1, 3, 2, 2, 2, 0, 1, 2,
+ 0, 1, 1, 2, 2, 7, 5, 7, 7, 5,
+ 9, 10, 7, 8, 2, 2, 3, 3, 2, 2,
+ 3, 3, 3, 3, 5, 5, 3, 5, 1, 2,
+ 0, 1, 4, 3, 3, 3, 3, 3, 3, 3,
+ 3, 4, 5, 2, 2, 2, 8, 8, 1, 3,
+ 0, 1, 0, 1, 1, 1, 1, 2, 1, 1,
+ 0, 1, 0, 1, 2};
const short QDeclarativeJSGrammar::action_default [] = {
- 0, 0, 0, 0, 0, 0, 22, 0, 170, 237,
- 201, 209, 205, 149, 221, 197, 3, 134, 68, 150,
- 213, 217, 138, 167, 148, 153, 133, 187, 174, 0,
- 75, 76, 71, 339, 63, 341, 0, 0, 0, 0,
- 73, 0, 0, 69, 72, 0, 0, 64, 66, 65,
- 74, 67, 0, 70, 0, 0, 163, 0, 0, 150,
- 169, 152, 151, 0, 0, 0, 165, 166, 164, 168,
- 0, 198, 0, 0, 0, 0, 188, 0, 0, 0,
- 0, 0, 0, 178, 0, 0, 0, 172, 173, 171,
- 176, 180, 179, 177, 175, 190, 189, 191, 0, 206,
- 0, 202, 0, 0, 144, 131, 143, 132, 100, 101,
- 102, 127, 103, 128, 104, 105, 106, 107, 108, 109,
- 110, 111, 112, 113, 114, 115, 116, 129, 117, 118,
- 119, 120, 121, 122, 123, 124, 125, 126, 130, 0,
- 0, 142, 238, 145, 0, 146, 0, 147, 141, 0,
- 234, 227, 225, 232, 233, 231, 230, 236, 229, 228,
- 226, 235, 222, 0, 210, 0, 0, 214, 0, 0,
- 218, 0, 0, 144, 136, 0, 135, 0, 140, 154,
- 0, 340, 329, 330, 0, 327, 0, 328, 0, 331,
- 245, 252, 251, 259, 247, 0, 248, 332, 0, 338,
- 249, 250, 255, 253, 335, 333, 337, 256, 0, 267,
- 0, 0, 0, 0, 339, 63, 0, 341, 64, 239,
- 281, 65, 0, 0, 0, 268, 0, 0, 257, 258,
- 0, 246, 254, 282, 283, 326, 336, 0, 297, 298,
- 299, 300, 0, 293, 294, 295, 296, 323, 324, 0,
- 0, 0, 0, 0, 286, 287, 243, 241, 203, 211,
- 207, 223, 199, 244, 0, 150, 215, 219, 192, 181,
- 0, 0, 200, 0, 0, 0, 0, 193, 0, 0,
- 0, 0, 0, 185, 183, 186, 184, 182, 195, 194,
- 196, 0, 208, 0, 204, 0, 242, 150, 0, 224,
- 239, 240, 0, 239, 0, 0, 289, 0, 0, 0,
- 291, 0, 212, 0, 0, 216, 0, 0, 220, 279,
- 0, 271, 280, 274, 0, 278, 0, 239, 272, 0,
- 239, 0, 0, 290, 0, 0, 0, 292, 340, 329,
- 0, 0, 331, 0, 325, 0, 315, 0, 0, 0,
- 285, 0, 284, 0, 342, 0, 99, 261, 264, 0,
- 100, 267, 103, 128, 105, 106, 71, 110, 111, 63,
- 112, 115, 69, 72, 64, 239, 65, 74, 118, 67,
- 120, 70, 122, 123, 268, 125, 126, 130, 0, 92,
- 0, 0, 94, 98, 96, 83, 95, 97, 0, 93,
- 82, 262, 260, 138, 139, 144, 0, 137, 0, 314,
- 0, 301, 302, 0, 313, 0, 0, 0, 304, 309,
- 307, 310, 0, 0, 308, 309, 0, 305, 0, 306,
- 263, 312, 0, 263, 311, 0, 316, 317, 0, 263,
- 318, 319, 0, 0, 320, 0, 0, 0, 321, 322,
- 156, 155, 0, 0, 0, 288, 0, 0, 0, 303,
- 276, 269, 0, 277, 273, 0, 275, 265, 0, 266,
- 270, 86, 0, 0, 90, 77, 0, 79, 88, 0,
- 80, 89, 91, 81, 87, 78, 0, 84, 160, 158,
- 162, 159, 157, 161, 6, 334, 4, 2, 61, 85,
- 0, 0, 64, 66, 65, 31, 5, 0, 62, 0,
- 40, 39, 38, 0, 0, 53, 0, 54, 0, 59,
- 60, 0, 40, 0, 0, 0, 0, 0, 49, 50,
- 0, 51, 0, 52, 0, 55, 56, 0, 0, 0,
- 0, 0, 57, 58, 0, 47, 41, 48, 42, 0,
- 0, 0, 0, 44, 0, 45, 46, 43, 0, 0,
- 30, 34, 35, 36, 37, 138, 263, 0, 0, 100,
- 267, 103, 128, 105, 106, 71, 110, 111, 63, 112,
- 115, 69, 72, 64, 239, 65, 74, 118, 67, 120,
- 70, 122, 123, 268, 125, 126, 130, 138, 0, 26,
- 0, 0, 32, 27, 33, 28, 24, 0, 29, 25,
- 8, 0, 10, 0, 9, 0, 1, 21, 12, 0,
- 13, 0, 14, 0, 19, 20, 0, 15, 16, 0,
- 17, 18, 11, 23, 7, 343};
+ 0, 0, 0, 0, 0, 0, 22, 0, 172, 239,
+ 203, 211, 207, 151, 223, 199, 3, 136, 70, 152,
+ 215, 219, 140, 169, 150, 155, 135, 189, 176, 0,
+ 77, 78, 73, 341, 64, 343, 0, 0, 0, 0,
+ 75, 0, 0, 71, 74, 68, 0, 0, 65, 67,
+ 66, 76, 69, 0, 72, 0, 0, 165, 0, 0,
+ 152, 171, 154, 153, 0, 0, 0, 167, 168, 166,
+ 170, 0, 200, 0, 0, 0, 0, 190, 0, 0,
+ 0, 0, 0, 0, 180, 0, 0, 0, 174, 175,
+ 173, 178, 182, 181, 179, 177, 192, 191, 193, 0,
+ 208, 0, 204, 0, 0, 146, 133, 145, 134, 102,
+ 103, 104, 129, 105, 130, 106, 107, 108, 109, 110,
+ 111, 112, 113, 114, 115, 116, 117, 118, 131, 119,
+ 120, 121, 122, 123, 124, 125, 126, 127, 128, 132,
+ 0, 0, 144, 240, 147, 0, 148, 0, 149, 143,
+ 0, 236, 229, 227, 234, 235, 233, 232, 238, 231,
+ 230, 228, 237, 224, 0, 212, 0, 0, 216, 0,
+ 0, 220, 0, 0, 146, 138, 0, 137, 0, 142,
+ 156, 0, 342, 331, 332, 0, 329, 0, 330, 0,
+ 333, 247, 254, 253, 261, 249, 0, 250, 334, 0,
+ 340, 251, 252, 257, 255, 337, 335, 339, 258, 0,
+ 269, 0, 0, 0, 0, 341, 64, 0, 343, 65,
+ 241, 283, 66, 0, 0, 0, 270, 0, 0, 259,
+ 260, 0, 248, 256, 284, 285, 328, 338, 0, 299,
+ 300, 301, 302, 0, 295, 296, 297, 298, 325, 326,
+ 0, 0, 0, 0, 0, 288, 289, 245, 243, 205,
+ 213, 209, 225, 201, 246, 0, 152, 217, 221, 194,
+ 183, 0, 0, 202, 0, 0, 0, 0, 195, 0,
+ 0, 0, 0, 0, 187, 185, 188, 186, 184, 197,
+ 196, 198, 0, 210, 0, 206, 0, 244, 152, 0,
+ 226, 241, 242, 0, 241, 0, 0, 291, 0, 0,
+ 0, 293, 0, 214, 0, 0, 218, 0, 0, 222,
+ 281, 0, 273, 282, 276, 0, 280, 0, 241, 274,
+ 0, 241, 0, 0, 292, 0, 0, 0, 294, 342,
+ 331, 0, 0, 333, 0, 327, 0, 317, 0, 0,
+ 0, 287, 0, 286, 0, 344, 0, 101, 263, 266,
+ 0, 102, 269, 105, 130, 107, 108, 73, 112, 113,
+ 64, 114, 117, 71, 74, 65, 241, 66, 76, 120,
+ 69, 122, 72, 124, 125, 270, 127, 128, 132, 0,
+ 94, 0, 0, 96, 100, 98, 85, 97, 99, 0,
+ 95, 84, 264, 262, 140, 141, 146, 0, 139, 0,
+ 316, 0, 303, 304, 0, 315, 0, 0, 0, 306,
+ 311, 309, 312, 0, 0, 310, 311, 0, 307, 0,
+ 308, 265, 314, 0, 265, 313, 0, 318, 319, 0,
+ 265, 320, 321, 0, 0, 322, 0, 0, 0, 323,
+ 324, 158, 157, 0, 0, 0, 290, 0, 0, 0,
+ 305, 278, 271, 0, 279, 275, 0, 277, 267, 0,
+ 268, 272, 88, 0, 0, 92, 79, 0, 81, 90,
+ 0, 82, 91, 93, 83, 89, 80, 0, 86, 162,
+ 160, 164, 161, 159, 163, 6, 336, 4, 2, 62,
+ 87, 0, 0, 65, 67, 66, 31, 5, 0, 63,
+ 0, 41, 40, 39, 0, 0, 54, 0, 55, 0,
+ 60, 61, 0, 41, 0, 0, 0, 0, 0, 50,
+ 51, 0, 52, 0, 53, 0, 56, 57, 0, 0,
+ 0, 0, 0, 58, 59, 0, 48, 42, 49, 43,
+ 0, 0, 0, 0, 45, 0, 46, 47, 44, 0,
+ 0, 0, 30, 35, 36, 37, 38, 140, 265, 0,
+ 0, 102, 269, 105, 130, 107, 108, 73, 112, 113,
+ 64, 114, 117, 71, 74, 65, 241, 66, 76, 120,
+ 69, 122, 72, 124, 125, 270, 127, 128, 132, 140,
+ 0, 26, 0, 0, 32, 27, 33, 28, 24, 0,
+ 29, 25, 0, 34, 8, 0, 10, 0, 9, 0,
+ 1, 21, 12, 0, 13, 0, 14, 0, 19, 20,
+ 0, 15, 16, 0, 17, 18, 11, 23, 7, 345};
const short QDeclarativeJSGrammar::goto_default [] = {
- 7, 616, 206, 195, 204, 506, 494, 615, 634, 610,
- 614, 612, 617, 22, 613, 18, 505, 607, 598, 560,
- 507, 190, 194, 196, 200, 523, 549, 548, 199, 231,
- 26, 473, 472, 355, 354, 9, 353, 356, 106, 17,
- 144, 24, 13, 143, 19, 25, 56, 23, 8, 28,
- 27, 268, 15, 262, 10, 258, 12, 260, 11, 259,
- 20, 266, 21, 267, 14, 261, 257, 298, 410, 263,
- 264, 201, 192, 191, 203, 232, 202, 207, 228, 229,
- 193, 359, 358, 230, 462, 461, 320, 321, 464, 323,
- 463, 322, 418, 422, 425, 421, 420, 440, 441, 184,
- 198, 180, 183, 197, 205, 0};
+ 7, 620, 207, 196, 205, 507, 495, 619, 638, 614,
+ 618, 616, 621, 22, 617, 18, 506, 609, 600, 562,
+ 508, 191, 195, 197, 201, 524, 550, 549, 200, 232,
+ 26, 474, 473, 356, 355, 9, 354, 357, 107, 17,
+ 145, 24, 13, 144, 19, 25, 57, 23, 8, 28,
+ 27, 269, 15, 263, 10, 259, 12, 261, 11, 260,
+ 20, 267, 21, 268, 14, 262, 258, 299, 411, 264,
+ 265, 202, 193, 192, 204, 233, 203, 208, 229, 230,
+ 194, 360, 359, 231, 463, 462, 321, 322, 465, 324,
+ 464, 323, 419, 423, 426, 422, 421, 441, 442, 185,
+ 199, 181, 184, 198, 206, 0};
const short QDeclarativeJSGrammar::action_index [] = {
- 439, 1109, 2228, 2228, 2132, 814, -74, 18, 147, -100,
- 31, -17, -49, 232, -100, 318, 85, -100, -100, 554,
- 33, 94, 331, 215, -100, -100, -100, 448, 231, 1109,
- -100, -100, -100, 320, -100, 1940, 1472, 1109, 1109, 1109,
- -100, 724, 1109, -100, -100, 1109, 1109, -100, -100, -100,
- -100, -100, 1109, -100, 1109, 1109, -100, 1109, 1109, 129,
- 157, -100, -100, 1109, 1109, 1109, -100, -100, -100, 200,
- 1109, 293, 1109, 1109, 1109, 1109, 466, 1109, 1109, 1109,
- 1109, 1109, 1109, 179, 1109, 1109, 1109, 119, 125, 95,
- 188, 198, 184, 203, 178, 567, 567, 484, 1109, -5,
- 1109, 67, 1844, 1109, 1109, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, 110,
- 1109, -100, -100, 70, 61, -100, 1109, -100, -100, 1109,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, 1109, 55, 1109, 1109, 73, 63, 1109,
- -100, 1844, 1109, 1109, -100, 141, -100, 41, -100, -100,
- 87, -100, 255, 80, 78, -100, 287, -100, 83, 2228,
- -100, -100, -100, -100, -100, 225, -100, -100, 52, -100,
- -100, -100, -100, -100, -100, 2228, -100, -100, 420, -100,
- 408, 113, 2132, 50, 330, 65, 46, 2420, 72, 1109,
- -100, 74, 75, 1109, 77, -100, 53, 56, -100, -100,
- 323, -100, -100, -100, -100, -100, -100, 96, -100, -100,
- -100, -100, 99, -100, -100, -100, -100, -100, -100, 60,
- 47, 1109, 118, 93, -100, -100, 1291, -100, 79, 66,
- 64, -100, 413, 76, 51, 664, 89, 97, 393, 183,
- 337, 1109, 413, 1109, 1109, 1109, 1109, 411, 1109, 1109,
- 1109, 1109, 1109, 252, 272, 212, 217, 221, 490, 490,
- 383, 1109, 64, 1109, 84, 1109, -100, 536, 1109, -100,
- 1109, 69, 68, 1109, 44, 2132, -100, 1109, 124, 2132,
- -100, 1109, 54, 1109, 1109, 71, 88, 1109, -100, 82,
- 122, 154, -100, -100, 1109, -100, 343, 1109, -100, 81,
- 1109, 90, 2132, -100, 1109, 112, 2132, -100, 86, 333,
- -39, -10, 2228, -33, -100, 2132, -100, 1109, 246, 2132,
- 4, 2132, -100, 10, 16, -21, -100, -100, 2132, -26,
- 480, 19, 462, 128, 1109, 2132, 6, -9, 400, 8,
- -22, 840, -3, -6, -100, 1202, -100, -7, -28, 5,
- 1109, 2, -23, 1109, 0, 1109, -34, -30, 1109, -100,
- 2036, 21, -100, -100, -100, -100, -100, -100, 1109, -100,
- -100, -100, -100, 209, -100, 1109, 40, -100, 2132, -100,
- 101, -100, -100, 2132, -100, 1109, 120, 43, -100, 62,
- -100, 59, 109, 1109, -100, 57, 58, -100, 39, -100,
- 2132, -100, 117, 2132, -100, 199, -100, -100, 107, 2132,
- 34, -100, 24, 11, -100, 346, -19, 14, -100, -100,
- -100, -100, 1109, 133, 2132, -100, 1109, 126, 2132, -100,
- 20, -100, 173, -100, -100, 1109, -100, -100, 303, -100,
- -100, -100, 100, 1656, -100, -100, 1564, -100, -100, 1748,
- -100, -100, -100, -100, -100, -100, 131, -100, -100, -100,
- -100, -100, -100, -100, -100, 2228, -100, -100, -100, 158,
- -20, 752, 165, -16, 22, -100, -100, 98, -100, 189,
- -100, -100, -100, 28, 170, -100, 1109, -100, 230, -100,
- -100, 247, 1, 13, 238, 37, -24, 106, -100, -100,
- 273, -100, 1109, -100, 265, -100, -100, 242, -4, 12,
- 1109, 241, -100, -100, 234, -100, 245, -100, 3, 9,
- 311, 190, 316, -100, 134, -100, -100, -100, 1380, 1020,
- -100, -100, -100, -100, -100, 359, 2324, 1472, 15, 444,
- 38, 394, 138, 1109, 2132, 36, 17, 397, 42, 23,
- 840, 32, 29, -100, 1202, -100, 26, 35, 48, 1109,
- 45, 25, 1109, 49, 1109, 27, 30, 314, 132, -100,
- 7, 752, -100, -100, -100, -100, -100, 930, -100, -100,
- -100, 752, -100, 253, -87, 617, -100, -100, 102, 290,
- -100, 191, -100, 140, -100, -100, 275, -100, -100, 91,
- -100, -100, -100, -100, -100, -100,
+ 314, 1273, 2404, 2404, 2307, 1001, 58, 98, 78, -101,
+ 95, 56, 4, 236, -101, 296, 86, -101, -101, 545,
+ 97, 115, 162, 197, -101, -101, -101, 447, 192, 1273,
+ -101, -101, -101, 369, -101, 2113, 1919, 1273, 1273, 1273,
+ -101, 732, 1273, -101, -101, -101, 1273, 1273, -101, -101,
+ -101, -101, -101, 1273, -101, 1273, 1273, -101, 1273, 1273,
+ 81, 195, -101, -101, 1273, 1273, 1273, -101, -101, -101,
+ 185, 1273, 283, 1273, 1273, 1273, 1273, 447, 1273, 1273,
+ 1273, 1273, 1273, 1273, 297, 1273, 1273, 1273, 107, 85,
+ 116, 297, 297, 297, 297, 191, 447, 447, 447, 1273,
+ 74, 1273, 102, 2016, 1273, 1273, -101, -101, -101, -101,
+ -101, -101, -101, -101, -101, -101, -101, -101, -101, -101,
+ -101, -101, -101, -101, -101, -101, -101, -101, -101, -101,
+ -101, -101, -101, -101, -101, -101, -101, -101, -101, -101,
+ 112, 1273, -101, -101, 92, 61, -101, 1273, -101, -101,
+ 1273, -101, -101, -101, -101, -101, -101, -101, -101, -101,
+ -101, -101, -101, -101, 1273, 36, 1273, 1273, 65, 62,
+ 1273, -101, 2016, 1273, 1273, -101, 127, -101, 42, -101,
+ -101, 57, -101, 294, 60, 35, -101, 259, -101, 32,
+ 2404, -101, -101, -101, -101, -101, 200, -101, -101, 33,
+ -101, -101, -101, -101, -101, -101, 2404, -101, -101, 436,
+ -101, 433, 100, 2307, 34, 369, 67, 45, 2598, 71,
+ 1273, -101, 72, 51, 1273, 59, -101, 54, 55, -101,
+ -101, 324, -101, -101, -101, -101, -101, -101, 88, -101,
+ -101, -101, -101, 76, -101, -101, -101, -101, -101, -101,
+ 5, 49, 1273, 104, 84, -101, -101, 1457, -101, 70,
+ 41, 1, -101, 287, 68, 46, 643, 73, 77, 364,
+ 297, 369, 1273, 238, 1273, 1273, 1273, 1273, 341, 1273,
+ 1273, 1273, 1273, 1273, 297, 175, 167, 161, 176, 348,
+ 315, 331, 1273, -13, 1273, 63, 1273, -101, 545, 1273,
+ -101, 1273, 64, 40, 1273, 2, 2307, -101, 1273, 152,
+ 2307, -101, 1273, 69, 1273, 1273, 75, 79, 1273, -101,
+ 44, 149, 66, -101, -101, 1273, -101, 369, 1273, -101,
+ 52, 1273, -54, 2307, -101, 1273, 151, 2307, -101, -29,
+ 369, -41, -11, 2404, -46, -101, 2307, -101, 1273, 131,
+ 2307, -5, 2307, -101, 8, 13, -55, -101, -101, 2307,
+ -51, 360, -2, 352, 119, 1273, 2307, 39, -19, 366,
+ 3, -24, 910, 6, 7, -101, 1367, -101, 11, -16,
+ -4, 1273, -6, -31, 1273, 9, 1273, -12, 17, 1273,
+ -101, 2210, 37, -101, -101, -101, -101, -101, -101, 1273,
+ -101, -101, -101, -101, 258, -101, 1273, -15, -101, 2307,
+ -101, 117, -101, -101, 2307, -101, 1273, 106, 16, -101,
+ 38, -101, 135, 96, 1273, -101, 135, 43, -101, 18,
+ -101, 2307, -101, 101, 2307, -101, 179, -101, -101, 99,
+ 2307, 31, -101, -7, -8, -101, 369, -34, -1, -101,
+ -101, -101, -101, 1273, 124, 2307, -101, 1273, 122, 2307,
+ -101, 25, -101, 207, -101, -101, 1273, -101, -101, 290,
+ -101, -101, -101, 114, 1733, -101, -101, 1826, -101, -101,
+ 1550, -101, -101, -101, -101, -101, -101, 103, -101, -101,
+ -101, -101, -101, -101, -101, -101, 2404, -101, -101, -101,
+ 221, -43, 704, 164, -26, 12, -101, -101, 188, -101,
+ 196, -101, -101, -101, 369, 183, -101, 1273, -101, 165,
+ -101, -101, 170, 0, 369, 160, 10, 369, 113, -101,
+ -101, 215, -101, 1273, -101, 225, -101, -101, 203, 369,
+ 28, 1273, 229, -101, -101, 202, -101, 218, -101, 30,
+ -21, 369, 199, 278, -101, 110, -101, -101, -101, 1640,
+ 1092, 583, -101, -101, -101, -101, -101, 284, 2501, 1919,
+ 14, 388, 29, 424, 93, 1273, 2307, 39, -9, 338,
+ 21, -3, 821, 24, 23, -101, 1367, -101, 48, 20,
+ 47, 1273, 50, 26, 1273, 53, 1273, 27, 22, 264,
+ 120, -101, 15, 813, -101, -101, -101, -101, -101, 1183,
+ -101, -101, 19, -101, -101, 498, -101, 249, -82, 902,
+ -101, -101, 118, 369, -101, 204, -101, 80, -101, -101,
+ 369, -101, -101, 82, -101, -101, -101, -101, -101, -101,
- -106, 12, -87, 18, 17, 212, -106, -106, -106, -106,
- -106, -106, -106, -106, -106, -106, -106, -106, -106, -53,
- -106, -106, -106, -106, -106, -106, -106, -106, -106, 162,
- -106, -106, -106, -4, -106, -106, -11, 24, 75, 76,
- -106, 83, 55, -106, -106, 157, 158, -106, -106, -106,
- -106, -106, 150, -106, 172, 176, -106, 168, 167, -106,
- -106, -106, -106, 173, 154, 115, -106, -106, -106, -106,
- 147, -106, 121, 113, 112, 125, -106, 128, 143, 146,
- 140, 139, 136, -106, 122, 138, 130, -106, -106, -106,
- -106, -106, -106, -106, -106, -106, -106, -106, 149, -106,
- 153, -106, 110, 82, 46, -106, -106, -106, -106, -106,
- -106, -106, -106, -106, -106, -106, -106, -106, -106, -106,
- -106, -106, -106, -106, -106, -106, -106, -106, -106, -106,
+ -106, 17, -83, 19, 24, 228, -106, -106, -106, -106,
+ -106, -106, -106, -106, -106, -106, -106, -106, -106, -49,
+ -106, -106, -106, -106, -106, -106, -106, -106, -106, 101,
+ -106, -106, -106, 2, -106, -106, -2, 29, 107, 166,
+ -106, 204, 183, -106, -106, -106, 174, 169, -106, -106,
+ -106, -106, -106, 145, -106, 141, 137, -106, 152, 161,
+ -106, -106, -106, -106, 163, 158, 157, -106, -106, -106,
+ -106, 132, -106, 142, 138, 187, 178, -106, 167, 181,
+ 81, 82, 85, 83, -106, 93, 114, 96, -106, -106,
+ -106, -106, -106, -106, -106, -106, -106, -106, -106, 170,
+ -106, 74, -106, 109, 80, 51, -106, -106, -106, -106,
-106, -106, -106, -106, -106, -106, -106, -106, -106, -106,
- 35, -106, -106, -106, -106, -106, 37, -106, -106, 45,
-106, -106, -106, -106, -106, -106, -106, -106, -106, -106,
- -106, -106, -106, 92, -106, 88, 58, -106, -106, 51,
- -106, 209, 72, 78, -106, -106, -106, -106, -106, -106,
- -106, -106, 27, -106, -106, -106, 63, -106, -106, -106,
-106, -106, -106, -106, -106, -106, -106, -106, -106, -106,
- -106, -106, -106, -106, -106, 50, -106, -106, 28, -106,
- 29, -106, 47, -106, 33, -106, -106, 66, -106, 73,
- -106, -106, -106, 81, 53, -106, -106, -106, -106, -106,
- -13, -106, -106, -106, -106, -106, -106, -106, -106, -106,
+ -106, 25, -106, -106, -106, -106, -106, 41, -106, -106,
+ 50, -106, -106, -106, -106, -106, -106, -106, -106, -106,
+ -106, -106, -106, -106, 98, -106, 104, 43, -106, -106,
+ 42, -106, 221, 64, 117, -106, -106, -106, -106, -106,
+ -106, -106, -106, 54, -106, -106, -106, 55, -106, -106,
-106, -106, -106, -106, -106, -106, -106, -106, -106, -106,
- -106, 9, -106, -106, -106, -106, 111, -106, -106, -106,
+ -106, -106, -106, -106, -106, -106, 47, -106, -106, 38,
+ -106, 33, -106, 92, -106, 73, -106, -106, 88, -106,
+ 86, -106, -106, -106, 94, 23, -106, -106, -106, -106,
+ -106, -11, -106, -106, -106, -106, -106, -106, -106, -106,
-106, -106, -106, -106, -106, -106, -106, -106, -106, -106,
- 3, 186, -106, 220, 228, 234, 204, -106, 90, 91,
- 94, 97, 93, -106, -106, -106, -106, -106, -106, -106,
- -106, 210, -106, 187, -106, 214, -106, -106, 208, -106,
- 207, -106, -106, 155, -106, 8, -106, 4, -106, -1,
- -106, 217, -106, 177, 185, -106, -106, 184, -106, -106,
- -106, -106, -106, -106, 183, -106, 194, 105, -106, -106,
- 99, -106, 71, -106, 74, -106, 65, -106, -106, 114,
- -106, -106, -55, -106, -106, 64, -106, 44, -106, 30,
- -106, 31, -106, -106, -106, -106, -106, -106, 57, -106,
- 36, -106, 40, -106, 70, 59, -106, -106, 42, -106,
- -106, 104, -106, -106, -106, 38, -106, -106, -106, -106,
- 79, -106, 69, 108, -106, 84, -106, -106, 56, -106,
- 68, -106, -106, -106, -106, -106, -106, -106, 52, -106,
- -106, -106, -106, -106, -106, 109, -106, -106, 77, -106,
- -106, -106, -106, 86, -106, 80, -106, -106, -106, -106,
- -106, -59, -106, 43, -106, -63, -106, -106, -106, -106,
- 98, -106, -106, 95, -106, -106, -106, -106, -106, 60,
- -34, -106, -106, 32, -106, 41, -106, 39, -106, -106,
- -106, -106, 49, -106, 61, -106, 62, -106, 48, -106,
- -106, -106, -106, -106, -106, 23, -106, -106, 96, -106,
- -106, -106, -106, 34, -106, -106, 133, -106, -106, 54,
+ -106, -106, 22, -106, -106, -106, -106, 105, -106, -106,
-106, -106, -106, -106, -106, -106, -106, -106, -106, -106,
- -106, -106, -106, -106, -106, 67, -106, -106, -106, -106,
- -106, 22, -106, -106, -106, -106, -106, -106, -106, -22,
- -106, -106, -106, -106, -106, -106, 2, -106, -106, -106,
- -106, -106, -106, -106, -19, -106, -106, -106, -106, -106,
- -106, -106, 100, -106, -106, -106, -106, -21, -106, -106,
- -3, -106, -106, -106, -106, -106, 13, -106, -106, -106,
- 11, 14, 10, -106, -106, -106, -106, -106, 279, 283,
- -106, -106, -106, -106, -106, -106, 19, 273, 15, 16,
- -106, 21, -106, 224, 6, -106, -106, 25, -106, -106,
- 85, -106, -106, -106, 26, -106, -106, -106, -106, 20,
- -106, 7, 87, -106, 107, -106, -106, -106, -106, -106,
- -106, 317, -106, -106, -106, -106, -106, 277, -106, -106,
- -106, 0, -106, -106, -2, 271, -106, -106, -106, 1,
- -106, -106, -106, -106, -106, -106, 5, -106, -106, -106,
- -106, -106, -106, -106, -106, -106};
+ -106, 7, 235, -106, 249, 219, 216, 222, -106, 124,
+ 125, 123, 122, 116, -106, -106, -106, -106, -106, -106,
+ -106, -106, 191, -106, 232, -106, 225, -106, -106, 231,
+ -106, 156, -106, -106, 130, -106, 91, -106, 5, -106,
+ 8, -106, 233, -106, 200, 189, -106, -106, 198, -106,
+ -106, -106, -106, -106, -106, 245, -106, 108, 95, -106,
+ -106, 298, -106, 195, -106, 89, -106, 71, -106, -106,
+ 120, -106, -106, -5, -106, -106, 52, -106, 53, -106,
+ 56, -106, 60, -106, -106, -106, -106, -106, -106, 39,
+ -106, 37, -106, 49, -106, 133, 69, -106, -106, 59,
+ -106, -106, 102, -106, -106, -106, 79, -106, -106, -106,
+ -106, 62, -106, 45, 67, -106, 75, -106, -106, 44,
+ -106, 1, -106, -106, -106, -106, -106, -106, -106, 46,
+ -106, -106, -106, -106, -106, -106, 115, -106, -106, 66,
+ -106, -106, -106, -106, 70, -106, 77, -106, -106, -106,
+ -106, -106, -9, -106, 72, -106, -38, -106, -106, -106,
+ -106, 97, -106, -106, 99, -106, -106, -106, -106, -106,
+ 40, -51, -106, -106, 36, -106, 34, -106, 63, -106,
+ -106, -106, -106, 35, -106, 48, -106, 58, -106, 57,
+ -106, -106, -106, -106, -106, -106, 28, -106, -106, 90,
+ -106, -106, -106, -106, 65, -106, -106, 159, -106, -106,
+ 61, -106, -106, -106, -106, -106, -106, -106, -106, -106,
+ -106, -106, -106, -106, -106, -106, 87, -106, -106, -106,
+ -106, -106, -13, -106, -106, -106, -106, -106, -106, -106,
+ -18, -106, -106, -106, -10, -106, -106, 0, -106, -106,
+ -106, -106, -106, -106, -4, -12, -106, -6, -106, -106,
+ -106, -106, -106, 3, -106, -106, -106, -106, -23, -14,
+ -106, 11, -106, -106, -106, -106, -106, 15, -106, -106,
+ -106, 16, 18, 14, -106, -106, -106, -106, -106, 292,
+ 399, 180, -106, -106, -106, -106, -106, -106, 26, 286,
+ 20, 21, -106, 30, -106, 177, 10, -106, -106, 31,
+ -106, -106, 193, -106, -106, -106, 32, -106, -106, -106,
+ -106, 27, -106, 13, 76, -106, 68, -106, -106, -106,
+ -106, -106, -106, 230, -106, -106, -106, -106, -106, 290,
+ -106, -106, -3, -106, -106, 6, -106, -106, 4, 270,
+ -106, -106, -106, 9, -106, -106, -106, -106, -106, -106,
+ 12, -106, -106, -106, -106, -106, -106, -106, -106, -106};
const short QDeclarativeJSGrammar::action_info [] = {
- -97, -98, 452, 611, -116, 527, 456, -124, 415, -121,
- 439, 551, -119, -108, 347, -94, 611, 388, 635, 540,
- 351, 341, 344, 342, 390, 539, -127, 256, 398, 402,
- 100, 98, 70, -97, 400, 163, -98, 465, 524, -116,
- 559, 447, 530, -108, 439, -127, 509, 439, 559, -94,
- 537, 544, -121, 256, 443, -119, -124, 514, 439, 347,
- 445, 526, 423, 452, 423, 430, 456, 423, 70, 554,
- 169, 415, 345, 311, 100, 163, 419, 140, 146, 408,
- 271, 413, 347, 251, 295, 271, 256, 0, 186, 452,
- 0, 311, 456, 140, 429, 317, 0, 0, 0, 324,
- 407, 178, 291, 98, 305, 558, 0, 235, 476, 0,
- 439, 415, 300, 442, 291, 0, 189, 171, 140, 426,
- 140, 148, 339, 182, 433, 140, 140, 443, 140, 303,
- 326, 559, 140, 0, 140, 57, 172, 250, 188, 140,
- 601, 140, 330, 293, 165, 0, 58, 313, 166, 140,
- 332, 314, 631, 630, 255, 254, 477, 241, 240, 57,
- 246, 245, 412, 411, 427, 57, 141, 529, 528, 63,
- 58, 61, 336, 171, 248, 247, 58, 516, 253, 0,
- 417, 468, 62, 327, 309, 334, 458, 57, 602, 248,
- 247, 487, 172, 454, 522, 556, 555, 176, 58, 248,
- 247, 625, 624, 84, 84, 85, 85, 140, 84, 84,
- 85, 85, 63, 84, 64, 85, 86, 86, 510, 510,
- 65, 86, 86, 84, 171, 85, 86, 63, 84, 0,
- 85, 517, 515, 140, 469, 467, 86, 84, 140, 85,
- 512, 86, 84, 172, 85, 405, 84, 102, 85, 140,
- 86, 511, 628, 627, 140, 86, 84, 64, 85, 86,
- 437, 436, 171, 65, 512, 512, 103, 510, 104, 86,
- 546, 510, 64, 140, 510, 511, 511, 84, 65, 85,
- 532, 172, 626, 405, 34, 0, 234, 233, 0, 0,
- 86, 520, 519, 0, 0, 547, 545, 84, 0, 85,
- 621, 0, 543, 542, 34, 0, 349, 0, 0, 0,
- 86, 72, 73, 512, 622, 620, 34, 512, 0, 34,
- 512, 47, 49, 48, 511, 0, 536, 535, 511, 171,
- 0, 511, 34, 0, 533, 531, 72, 73, 74, 75,
- 34, 47, 49, 48, 619, 34, 171, -85, 172, 34,
- 173, 0, 34, 47, 49, 48, 47, 49, 48, 34,
- 0, 0, 34, 74, 75, 172, 34, 173, 0, 47,
- 49, 48, 34, 0, 171, 34, 0, 47, 49, 48,
- 0, 0, 47, 49, 48, 0, 47, 49, 48, 47,
- 49, 48, -85, 172, 0, 173, 47, 49, 48, 47,
- 49, 48, 0, 47, 49, 48, 278, 279, 0, 47,
- 49, 48, 47, 49, 48, 280, 278, 279, 281, 0,
- 282, 0, 0, 34, 0, 280, 34, 0, 281, 34,
- 282, 273, 274, -339, 278, 279, -339, 34, 0, 0,
- 0, 0, 0, 280, 0, 0, 281, 0, 282, 34,
- 0, 0, 0, 0, 0, 244, 243, 0, 275, 276,
- 47, 49, 48, 47, 49, 48, 47, 49, 48, 244,
- 243, 77, 78, 34, 47, 49, 48, 0, 0, 79,
- 80, 239, 238, 81, 0, 82, 47, 49, 48, 77,
- 78, 34, 0, 0, 0, 0, 0, 79, 80, 0,
- 0, 81, 0, 82, 0, 239, 238, 77, 78, 34,
- 47, 49, 48, 278, 279, 79, 80, 0, 0, 81,
- 0, 82, 280, 244, 243, 281, 0, 282, 47, 49,
- 48, 6, 5, 4, 1, 3, 2, 0, 0, 150,
- 0, 239, 238, 0, 0, 0, 47, 49, 48, 151,
- 0, 0, 0, 152, 0, 0, 0, 150, 0, 0,
- 0, 0, 153, 0, 154, 0, 0, 151, 0, 0,
- 0, 152, 0, 0, 0, 155, 0, 156, 61, 0,
- 153, 0, 154, 0, 0, 157, 0, 0, 158, 62,
- 77, 78, 0, 155, 159, 156, 61, 0, 79, 80,
- 160, 0, 81, 157, 82, 0, 158, 62, 0, 0,
- 0, 0, 159, 0, 0, 0, 161, 0, 160, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 30,
- 31, 0, 0, 0, 161, 0, 0, 0, 0, 33,
- 0, 0, 0, 0, 0, 0, 34, 0, 0, 0,
- 35, 36, 0, 37, 0, 0, 0, 0, 0, 0,
- 501, 0, 0, 0, 44, 0, 0, 150, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 151, 0, 0,
- 0, 152, 50, 47, 49, 48, 0, 51, 0, 0,
- 153, 0, 154, 0, 0, 307, 0, 0, 43, 53,
- 32, 0, 0, 155, 40, 156, 61, 0, 0, 0,
- 0, 0, 0, 157, 0, 0, 158, 62, 0, 0,
- 0, 0, 159, 0, 0, 0, 0, 0, 160, 0,
+ 401, -123, 440, -121, 403, -129, 333, 340, 615, 345,
+ -96, 352, 348, -118, -100, 389, -126, 257, -99, 342,
+ 416, 391, 343, 510, 453, 440, 448, 257, -96, 446,
+ -100, -118, 440, 348, 527, 541, -129, 525, 552, 555,
+ 538, 545, 466, 424, 399, 408, -110, 560, 560, 420,
+ 431, 444, 560, 457, -121, -99, 416, -123, 457, 440,
+ -126, 325, 306, 453, 272, 190, 294, 164, 187, 170,
+ 257, 272, 141, 430, 346, 312, 296, 312, 409, 414,
+ 294, 348, 251, 101, 99, 252, 318, 416, 236, 292,
+ 453, 457, 440, 183, 141, 189, 71, 335, 639, 164,
+ 147, 304, 179, 71, 99, 443, 427, 301, 434, 141,
+ 0, 141, 141, 331, 141, 0, 0, 292, 58, 444,
+ 141, 149, 477, 62, 0, 58, 0, 314, 603, 59,
+ 141, 315, 141, 172, 63, 141, 59, 247, 246, 141,
+ 424, 629, 628, 635, 634, 256, 255, 58, 615, 242,
+ 241, 428, 173, 101, 249, 248, 58, 327, 59, 141,
+ 141, 249, 248, 488, 254, 166, 418, 59, 142, 167,
+ 478, 557, 556, 141, 530, 529, 604, 172, 413, 412,
+ 249, 248, 459, 177, 455, 172, 85, 141, 86, 511,
+ 517, 350, 85, 523, 86, 559, 173, 64, 174, 87,
+ 85, 85, 86, 86, 173, 87, 406, 64, 141, 64,
+ 328, 337, 310, 87, 87, 469, 85, 85, 86, 86,
+ 0, 560, 533, 0, 0, 511, 521, 520, 511, 87,
+ 87, 0, 511, 141, 0, 513, 172, 141, 547, 513,
+ 438, 437, 65, 0, 518, 516, 512, 511, 66, 0,
+ 512, 103, 65, 0, 65, 173, 274, 275, 66, 0,
+ 66, 235, 234, 548, 546, 632, 631, 0, 470, 468,
+ 104, 513, 105, 172, 513, 0, 534, 532, 513, 172,
+ 561, 0, 512, 276, 277, 512, 537, 536, 34, 512,
+ 544, 543, 173, 513, 406, 630, 625, -87, 173, 172,
+ 174, 73, 74, 0, 512, 274, 275, 34, 0, 0,
+ 626, 624, 0, 0, 73, 74, 0, -87, 173, 34,
+ 174, 0, 85, 34, 86, 48, 50, 49, 75, 76,
+ 0, 0, 276, 277, 0, 87, 0, 0, 279, 280,
+ 623, 75, 76, 0, 48, 50, 49, 281, 0, 0,
+ 282, 45, 283, 34, 279, 280, 48, 50, 49, 0,
+ 48, 50, 49, 281, 279, 280, 282, 34, 283, 0,
+ 45, 279, 280, 281, -341, 0, 282, 0, 283, 0,
+ 281, 34, 45, 282, 0, 283, 45, 279, 280, 34,
+ 48, 50, 49, 0, 0, 34, 281, 0, 34, 282,
+ 0, 283, -341, 0, 48, 50, 49, 6, 5, 4,
+ 1, 3, 2, 245, 244, 0, 45, 34, 48, 50,
+ 49, 240, 239, 0, 0, 0, 48, 50, 49, 0,
+ 45, 0, 48, 50, 49, 48, 50, 49, 0, 0,
+ 0, 0, 0, 0, 45, 0, 0, 0, 0, 240,
+ 239, 0, 45, 34, 48, 50, 49, 0, 45, 0,
+ 0, 45, 34, 0, 0, 34, 0, 0, 0, 0,
+ 78, 79, 0, 0, 0, 0, 0, 0, 80, 81,
+ 45, 0, 82, 0, 83, 245, 244, 0, 0, 0,
+ 48, 50, 49, 0, 245, 244, 0, 240, 239, 48,
+ 50, 49, 48, 50, 49, 0, 0, 0, 0, 0,
+ 30, 31, 0, 0, 0, 0, 45, 0, 0, 0,
+ 33, 0, 0, 0, 0, 45, 0, 34, 45, 0,
+ 0, 35, 36, 0, 37, 0, 0, 0, 0, 0,
+ 0, 502, 0, 0, 0, 44, 0, 0, 151, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 152, 0,
+ 0, 0, 153, 51, 48, 50, 49, 0, 52, 0,
+ 0, 154, 0, 155, 0, 0, 0, 0, 0, 43,
+ 54, 32, 0, 0, 156, 40, 157, 62, 0, 0,
+ 45, 0, 0, 0, 158, 30, 31, 159, 63, 0,
+ 0, 0, 0, 160, 0, 33, 0, 0, 0, 161,
+ 0, 0, 34, 0, 0, 0, 35, 36, 0, 37,
+ 0, 0, 0, 0, 0, 162, 502, 0, 0, 0,
+ 44, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 151, 0, 51, 48,
+ 50, 49, 0, 52, 0, 0, 152, 0, 0, 0,
+ 153, 0, 0, 0, 43, 54, 32, 0, 0, 154,
+ 40, 155, 0, 0, 308, 45, 0, 0, 0, 0,
+ 0, 0, 156, 0, 157, 62, 0, 0, 0, 0,
+ 0, 0, 158, 0, 0, 159, 63, 0, 0, 0,
+ 0, 160, 0, 0, 0, 0, 0, 161, 0, 0,
0, 0, 0, 0, 0, 0, 30, 31, 0, 0,
- 0, 0, 0, 0, 161, 0, 33, 0, 0, 0,
+ 0, 0, 0, 162, 0, 0, 33, 0, 0, 0,
0, 0, 0, 34, 0, 0, 0, 35, 36, 0,
- 37, 0, 0, 0, 30, 31, 0, 41, 0, 0,
+ 37, 0, 0, 0, 30, 31, 0, 502, 0, 0,
0, 44, 0, 0, 33, 0, 0, 0, 0, 0,
- 0, 34, 0, 0, 0, 35, 36, 0, 37, 50,
- 47, 49, 48, 0, 51, 501, 0, 0, 0, 44,
- 0, 0, 0, 0, 0, 43, 53, 32, 0, 0,
- 0, 40, 0, 0, 0, 0, 0, 50, 47, 49,
- 48, 0, 51, 0, 500, 0, 30, 31, 0, 0,
- 0, 0, 0, 43, 53, 32, 214, 0, 0, 40,
- 0, 0, 0, 34, 0, 0, 0, 35, 36, 0,
- 37, 0, 30, 31, 0, 0, 0, 501, 0, 0,
- 0, 44, 33, 0, 0, 0, 0, 0, 0, 34,
- 0, 0, 0, 35, 36, 0, 37, 0, 0, 50,
- 502, 504, 503, 41, 51, 0, 0, 44, 0, 225,
- 0, 0, 0, 0, 0, 43, 53, 32, 209, 0,
- 0, 40, 0, 0, 0, 50, 47, 49, 48, 0,
- 51, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 43, 53, 32, 0, 0, 0, 40, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 500, 0, 30, 31, 0, 0, 0, 0, 0, 0,
- 0, 0, 214, 0, 0, 0, 0, 0, 0, 34,
- 0, 0, 0, 35, 36, 0, 37, 0, 0, 0,
- 0, 0, 0, 501, 0, 0, 0, 44, 0, 0,
- 0, 0, 0, 0, 0, 608, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 50, 502, 504, 503, 0,
- 51, 0, 0, 0, 0, 225, 0, 0, 0, 0,
- 0, 43, 53, 32, 209, 0, 0, 40, 0, 0,
+ 0, 34, 0, 0, 0, 35, 36, 0, 37, 51,
+ 48, 50, 49, 0, 52, 41, 0, 0, 0, 44,
+ 0, 0, 0, 0, 0, 43, 54, 32, 0, 0,
+ 0, 40, 0, 0, 0, 0, 45, 51, 48, 50,
+ 49, 0, 52, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 43, 54, 32, 0, 0, 0, 40,
+ 0, 0, 0, 0, 45, 30, 31, 0, 0, 0,
+ 0, 0, 0, 30, 31, 33, 0, 0, 0, 0,
+ 0, 0, 34, 33, 0, 0, 35, 36, 0, 37,
+ 34, 0, 0, 0, 35, 36, 502, 37, 0, 0,
+ 44, 0, 0, 0, 41, 0, 0, 0, 44, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 51, 48,
+ 50, 49, 0, 52, 0, 0, 51, 48, 50, 49,
+ 0, 52, 0, 0, 43, 54, 32, 0, 0, 0,
+ 40, 0, 43, 54, 32, 45, 0, 0, 40, 0,
+ 0, 0, 0, 45, 30, 31, 0, 0, 0, 0,
+ 0, 0, 30, 31, 33, 0, 0, 0, 0, 0,
+ 0, 34, 33, 0, 0, 35, 36, 0, 37, 34,
+ 0, 0, 0, 35, 36, 502, 37, 0, 0, 44,
+ 0, 0, 0, 41, 0, 0, 0, 44, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 51, 48, 50,
+ 49, 0, 52, 0, 0, 51, 48, 50, 49, 0,
+ 52, 0, 0, 43, 54, 32, 0, 0, 0, 40,
+ 0, 43, 54, 32, 45, 0, 0, 40, 0, 0,
+ 0, 0, 45, 0, 0, 0, 0, 0, 0, 0,
+ 0, 501, 0, 30, 31, 0, 0, 0, 0, 0,
+ 0, 0, 0, 215, 0, 0, 0, 0, 0, 0,
+ 34, 0, 0, 0, 35, 36, 0, 37, 0, 0,
+ 0, 0, 0, 0, 502, 0, 0, 0, 44, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 500, 0, 30, 31, 0, 0, 0, 0, 0, 0,
- 0, 0, 214, 0, 0, 0, 0, 0, 0, 34,
+ 0, 0, 0, 0, 0, 0, 51, 503, 505, 504,
+ 0, 52, 0, 0, 0, 0, 226, 0, 0, 0,
+ 0, 0, 43, 54, 32, 210, 0, 0, 40, 0,
+ 0, 0, 0, 45, 0, 0, 0, 0, 0, 0,
+ 0, 0, 501, 0, 30, 31, 0, 0, 0, 0,
+ 0, 0, 0, 0, 215, 0, 0, 0, 0, 0,
+ 0, 34, 0, 0, 0, 35, 36, 0, 37, 0,
+ 0, 0, 0, 0, 0, 502, 0, 0, 0, 44,
+ 0, 0, 0, 0, 0, 0, 0, 607, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 51, 503, 505,
+ 504, 0, 52, 0, 0, 0, 0, 226, 0, 0,
+ 0, 0, 0, 43, 54, 32, 210, 0, 0, 40,
+ 0, 0, 0, 0, 45, 0, 0, 0, 0, 0,
+ 0, 0, 0, 501, 0, 30, 31, 0, 0, 0,
+ 0, 0, 0, 0, 0, 215, 0, 0, 0, 0,
+ 0, 0, 34, 0, 0, 0, 35, 36, 0, 37,
+ 0, 0, 0, 0, 0, 0, 502, 0, 0, 0,
+ 44, 0, 0, 0, 0, 0, 0, 0, 610, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 51, 503,
+ 505, 504, 0, 52, 0, 0, 0, 0, 226, 0,
+ 0, 0, 0, 0, 43, 54, 32, 210, 0, 0,
+ 40, 0, 0, 0, 0, 45, 0, 0, 0, 0,
+ 0, 0, 0, 0, 29, 30, 31, 0, 0, 0,
+ 0, 0, 0, 0, 0, 33, 0, 0, 0, 0,
+ 0, 0, 34, 0, 0, 0, 35, 36, 0, 37,
+ 0, 0, 0, 38, 0, 39, 41, 42, 0, 0,
+ 44, 0, 0, 0, 46, 0, 47, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 51, 48,
+ 50, 49, 0, 52, 0, 53, 0, 55, 0, 56,
+ 0, 0, 0, 0, 43, 54, 32, 0, 0, 0,
+ 40, 0, 0, 0, 0, 45, 0, 0, 0, 0,
+ 0, 0, 0, 0, -119, 0, 0, 0, 29, 30,
+ 31, 0, 0, 0, 0, 0, 0, 0, 0, 33,
+ 0, 0, 0, 0, 0, 0, 34, 0, 0, 0,
+ 35, 36, 0, 37, 0, 0, 0, 38, 0, 39,
+ 41, 42, 0, 0, 44, 0, 0, 0, 46, 0,
+ 47, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 51, 48, 50, 49, 0, 52, 0, 53,
+ 0, 55, 0, 56, 0, 0, 0, 0, 43, 54,
+ 32, 0, 0, 0, 40, 0, 0, 0, 0, 45,
+ 0, 0, 0, 0, 0, 0, 0, 0, 29, 30,
+ 31, 0, 0, 0, 0, 0, 0, 0, 0, 33,
+ 0, 0, 0, 0, 0, 0, 34, 0, 0, 0,
+ 35, 36, 0, 37, 0, 0, 0, 38, 0, 39,
+ 41, 42, 0, 0, 44, 0, 0, 0, 46, 0,
+ 47, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 51, 48, 50, 49, 0, 52, 0, 53,
+ 0, 55, 271, 56, 0, 0, 0, 0, 43, 54,
+ 32, 0, 0, 0, 40, 0, 0, 0, 0, 45,
+ 0, 0, 0, 0, 0, 0, 0, 0, 483, 0,
+ 0, 29, 30, 31, 0, 0, 0, 0, 0, 0,
+ 0, 0, 33, 0, 0, 0, 0, 0, 0, 34,
0, 0, 0, 35, 36, 0, 37, 0, 0, 0,
- 0, 0, 0, 501, 0, 0, 0, 44, 0, 0,
- 0, 0, 0, 0, 0, 605, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 50, 502, 504, 503, 0,
- 51, 0, 0, 0, 0, 225, 0, 0, 0, 0,
- 0, 43, 53, 32, 209, 0, 0, 40, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 38, 0, 39, 41, 42, 0, 0, 44, 0, 0,
+ 0, 46, 0, 47, 0, 0, 484, 0, 0, 0,
+ 0, 0, 0, 0, 0, 51, 48, 50, 49, 0,
+ 52, 0, 53, 0, 55, 0, 56, 0, 0, 0,
+ 0, 43, 54, 32, 0, 0, 0, 40, 0, 0,
+ 0, 0, 45, 0, 0, 0, 0, 0, 0, 0,
+ 0, 29, 30, 31, 0, 0, 0, 0, 0, 0,
+ 0, 0, 33, 0, 0, 0, 0, 0, 0, 34,
+ 217, 0, 0, 568, 569, 0, 37, 0, 0, 0,
+ 38, 0, 39, 41, 42, 0, 0, 44, 0, 0,
+ 0, 46, 0, 47, 0, 0, 0, 0, 0, 0,
+ 0, 221, 0, 0, 0, 51, 48, 50, 49, 0,
+ 52, 0, 53, 0, 55, 0, 56, 0, 0, 0,
+ 0, 43, 54, 32, 0, 0, 0, 40, 0, 0,
+ 0, 0, 45, 0, 0, 0, 0, 0, 0, 0,
+ 0, 483, 0, 0, 29, 30, 31, 0, 0, 0,
+ 0, 0, 0, 0, 0, 33, 0, 0, 0, 0,
+ 0, 0, 34, 0, 0, 0, 35, 36, 0, 37,
+ 0, 0, 0, 38, 0, 39, 41, 42, 0, 0,
+ 44, 0, 0, 0, 46, 0, 47, 0, 0, 486,
+ 0, 0, 0, 0, 0, 0, 0, 0, 51, 48,
+ 50, 49, 0, 52, 0, 53, 0, 55, 0, 56,
+ 0, 0, 0, 0, 43, 54, 32, 0, 0, 0,
+ 40, 0, 0, 0, 0, 45, 0, 0, 0, 0,
+ 0, 0, 0, 0, 475, 0, 0, 29, 30, 31,
+ 0, 0, 0, 0, 0, 0, 0, 0, 33, 0,
+ 0, 0, 0, 0, 0, 34, 0, 0, 0, 35,
+ 36, 0, 37, 0, 0, 0, 38, 0, 39, 41,
+ 42, 0, 0, 44, 0, 0, 0, 46, 0, 47,
+ 0, 0, 481, 0, 0, 0, 0, 0, 0, 0,
+ 0, 51, 48, 50, 49, 0, 52, 0, 53, 0,
+ 55, 0, 56, 0, 0, 0, 0, 43, 54, 32,
+ 0, 0, 0, 40, 0, 0, 0, 0, 45, 0,
+ 0, 0, 0, 0, 0, 0, 0, 475, 0, 0,
29, 30, 31, 0, 0, 0, 0, 0, 0, 0,
0, 33, 0, 0, 0, 0, 0, 0, 34, 0,
0, 0, 35, 36, 0, 37, 0, 0, 0, 38,
0, 39, 41, 42, 0, 0, 44, 0, 0, 0,
- 45, 0, 46, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 50, 47, 49, 48, 0, 51,
- 0, 52, 0, 54, 0, 55, 0, 0, 0, 0,
- 43, 53, 32, 0, 0, 0, 40, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, -117,
- 0, 0, 0, 29, 30, 31, 0, 0, 0, 0,
- 0, 0, 0, 0, 33, 0, 0, 0, 0, 0,
- 0, 34, 0, 0, 0, 35, 36, 0, 37, 0,
- 0, 0, 38, 0, 39, 41, 42, 0, 0, 44,
- 0, 0, 0, 45, 0, 46, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 50, 47, 49,
- 48, 0, 51, 0, 52, 0, 54, 0, 55, 0,
- 0, 0, 0, 43, 53, 32, 0, 0, 0, 40,
+ 46, 0, 47, 0, 0, 476, 0, 0, 0, 0,
+ 0, 0, 0, 0, 51, 48, 50, 49, 0, 52,
+ 0, 53, 0, 55, 0, 56, 0, 0, 0, 0,
+ 43, 54, 32, 0, 0, 0, 40, 0, 0, 0,
+ 0, 45, 0, 0, 0, 0, 0, 0, 0, 0,
+ 109, 110, 111, 0, 0, 113, 115, 116, 0, 0,
+ 117, 0, 118, 0, 0, 0, 120, 121, 122, 0,
+ 0, 0, 0, 0, 0, 34, 123, 124, 125, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 126,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 29, 30, 31, 0, 0, 0, 0, 0,
- 0, 0, 0, 33, 0, 0, 0, 0, 0, 0,
- 34, 0, 0, 0, 35, 36, 0, 37, 0, 0,
- 0, 38, 0, 39, 41, 42, 0, 0, 44, 0,
- 0, 0, 45, 0, 46, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 50, 47, 49, 48,
- 0, 51, 0, 52, 0, 54, 270, 55, 0, 0,
- 0, 0, 43, 53, 32, 0, 0, 0, 40, 0,
+ 0, 0, 0, 0, 0, 129, 0, 0, 0, 0,
+ 0, 0, 48, 50, 49, 130, 131, 132, 0, 134,
+ 135, 136, 137, 138, 139, 0, 0, 127, 133, 119,
+ 112, 114, 128, 0, 0, 0, 0, 0, 45, 0,
+ 0, 0, 0, 0, 0, 0, 0, 109, 110, 111,
+ 0, 0, 113, 115, 116, 0, 0, 117, 0, 118,
+ 0, 0, 0, 120, 121, 122, 0, 0, 0, 0,
+ 0, 0, 393, 123, 124, 125, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 126, 0, 0, 0,
+ 394, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 129, 0, 0, 0, 0, 0, 398, 395,
+ 397, 0, 130, 131, 132, 0, 134, 135, 136, 137,
+ 138, 139, 0, 0, 127, 133, 119, 112, 114, 128,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 29, 30, 31, 0, 0, 0, 0, 0, 0,
- 0, 0, 33, 0, 0, 0, 0, 0, 0, 34,
- 216, 0, 0, 566, 567, 0, 37, 0, 0, 0,
- 38, 0, 39, 41, 42, 0, 0, 44, 0, 0,
- 0, 45, 0, 46, 0, 0, 0, 0, 0, 0,
- 0, 220, 0, 0, 0, 50, 47, 49, 48, 0,
- 51, 0, 52, 0, 54, 0, 55, 0, 0, 0,
- 0, 43, 53, 32, 0, 0, 0, 40, 0, 0,
+ 0, 0, 0, 0, 109, 110, 111, 0, 0, 113,
+ 115, 116, 0, 0, 117, 0, 118, 0, 0, 0,
+ 120, 121, 122, 0, 0, 0, 0, 0, 0, 393,
+ 123, 124, 125, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 126, 0, 0, 0, 394, 0, 0,
+ 0, 0, 0, 0, 0, 396, 0, 0, 0, 129,
+ 0, 0, 0, 0, 0, 398, 395, 397, 0, 130,
+ 131, 132, 0, 134, 135, 136, 137, 138, 139, 0,
+ 0, 127, 133, 119, 112, 114, 128, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 474, 0, 0, 29, 30, 31, 0, 0, 0, 0,
- 0, 0, 0, 0, 33, 0, 0, 0, 0, 0,
- 0, 34, 0, 0, 0, 35, 36, 0, 37, 0,
- 0, 0, 38, 0, 39, 41, 42, 0, 0, 44,
- 0, 0, 0, 45, 0, 46, 0, 0, 475, 0,
- 0, 0, 0, 0, 0, 0, 0, 50, 47, 49,
- 48, 0, 51, 0, 52, 0, 54, 0, 55, 0,
- 0, 0, 0, 43, 53, 32, 0, 0, 0, 40,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 474, 0, 0, 29, 30, 31, 0, 0,
- 0, 0, 0, 0, 0, 0, 33, 0, 0, 0,
- 0, 0, 0, 34, 0, 0, 0, 35, 36, 0,
+ 0, 209, 0, 0, 0, 0, 211, 0, 29, 30,
+ 31, 213, 0, 0, 0, 0, 0, 0, 214, 33,
+ 0, 0, 0, 0, 0, 0, 216, 217, 0, 0,
+ 218, 36, 0, 37, 0, 0, 0, 38, 0, 39,
+ 41, 42, 0, 0, 44, 0, 0, 0, 46, 0,
+ 47, 0, 0, 0, 0, 0, 220, 0, 221, 0,
+ 0, 0, 51, 219, 222, 49, 223, 52, 224, 53,
+ 225, 55, 226, 56, 227, 228, 0, 0, 43, 54,
+ 32, 210, 212, 0, 40, 0, 0, 0, 0, 45,
+ 0, 0, 0, 0, 0, 0, 0, 0, 209, 0,
+ 0, 0, 0, 211, 0, 29, 30, 31, 213, 0,
+ 0, 0, 0, 0, 0, 214, 215, 0, 0, 0,
+ 0, 0, 0, 216, 217, 0, 0, 218, 36, 0,
37, 0, 0, 0, 38, 0, 39, 41, 42, 0,
- 0, 44, 0, 0, 0, 45, 0, 46, 0, 0,
- 480, 0, 0, 0, 0, 0, 0, 0, 0, 50,
- 47, 49, 48, 0, 51, 0, 52, 0, 54, 0,
- 55, 0, 0, 0, 0, 43, 53, 32, 0, 0,
- 0, 40, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 482, 0, 0, 29, 30, 31,
- 0, 0, 0, 0, 0, 0, 0, 0, 33, 0,
- 0, 0, 0, 0, 0, 34, 0, 0, 0, 35,
- 36, 0, 37, 0, 0, 0, 38, 0, 39, 41,
- 42, 0, 0, 44, 0, 0, 0, 45, 0, 46,
- 0, 0, 485, 0, 0, 0, 0, 0, 0, 0,
- 0, 50, 47, 49, 48, 0, 51, 0, 52, 0,
- 54, 0, 55, 0, 0, 0, 0, 43, 53, 32,
- 0, 0, 0, 40, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 482, 0, 0, 29,
- 30, 31, 0, 0, 0, 0, 0, 0, 0, 0,
- 33, 0, 0, 0, 0, 0, 0, 34, 0, 0,
- 0, 35, 36, 0, 37, 0, 0, 0, 38, 0,
- 39, 41, 42, 0, 0, 44, 0, 0, 0, 45,
- 0, 46, 0, 0, 483, 0, 0, 0, 0, 0,
- 0, 0, 0, 50, 47, 49, 48, 0, 51, 0,
- 52, 0, 54, 0, 55, 0, 0, 0, 0, 43,
- 53, 32, 0, 0, 0, 40, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 108, 109,
- 110, 0, 0, 112, 114, 115, 0, 0, 116, 0,
- 117, 0, 0, 0, 119, 120, 121, 0, 0, 0,
- 0, 0, 0, 34, 122, 123, 124, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 125, 0, 0,
+ 0, 44, 0, 0, 0, 46, 0, 47, 0, 0,
+ 0, 0, 0, 220, 0, 221, 0, 0, 0, 51,
+ 219, 222, 49, 223, 52, 224, 53, 225, 55, 226,
+ 56, 227, 228, 0, 0, 43, 54, 32, 210, 212,
+ 0, 40, 0, 0, 0, 0, 45, 0, 0, 0,
+ 0, 0, 0, 0, 0, 571, 110, 111, 0, 0,
+ 573, 115, 575, 30, 31, 576, 0, 118, 0, 0,
+ 0, 120, 578, 579, 0, 0, 0, 0, 0, 0,
+ 580, 581, 124, 125, 218, 36, 0, 37, 0, 0,
+ 0, 38, 0, 39, 582, 42, 0, 0, 584, 0,
+ 0, 0, 46, 0, 47, 0, 0, 0, 0, 0,
+ 586, 0, 221, 0, 0, 0, 588, 585, 587, 49,
+ 589, 590, 591, 53, 593, 594, 595, 596, 597, 598,
+ 0, 0, 583, 592, 577, 572, 574, 128, 40, 0,
+ 0, 0, 0, 45, 0, 0, 0, 0, 0, 0,
+ 0, 0, 361, 110, 111, 0, 0, 363, 115, 365,
+ 30, 31, 366, 0, 118, 0, 0, 0, 120, 368,
+ 369, 0, 0, 0, 0, 0, 0, 370, 371, 124,
+ 125, 218, 36, 0, 37, 0, 0, 0, 38, 0,
+ 39, 372, 42, 0, 0, 374, 0, 0, 0, 46,
+ 0, 47, 0, -265, 0, 0, 0, 376, 0, 221,
+ 0, 0, 0, 378, 375, 377, 49, 379, 380, 381,
+ 53, 383, 384, 385, 386, 387, 388, 0, 0, 373,
+ 382, 367, 362, 364, 128, 40, 0, 0, 0, 0,
+ 45, 0, 0, 0, 0, 0, 0, 0, 0,
+
+ 522, 540, 539, 519, 461, 515, 535, 514, 309, 528,
+ 311, 531, 250, 526, 542, 636, 613, 182, 150, 622,
+ 16, 496, 320, 497, 627, 253, 498, 633, 358, 554,
+ 436, 558, 487, 472, 439, 302, 238, 392, 454, 606,
+ 551, 402, 358, 553, 439, 243, 182, 445, 243, 447,
+ 456, 237, 238, 238, 347, 429, 349, 450, 351, 460,
+ 143, 458, 353, 467, 243, 436, 439, 176, 410, 186,
+ 188, 250, 415, 338, 182, 433, 148, 171, 169, 390,
+ 417, 400, 302, 140, 449, 163, 146, 425, 339, 302,
+ 358, 237, 336, 307, 250, 344, 482, 436, 302, 358,
+ 485, 358, 0, 0, 0, 461, 0, 0, 0, 0,
+ 0, 60, 60, 451, 452, 404, 0, 0, 60, 60,
+ 60, 452, 451, 320, 106, 60, 60, 60, 102, 60,
+ 92, 93, 95, 302, 94, 186, 0, 60, 0, 0,
+ 60, 88, 60, 405, 90, 60, 108, 180, 60, 266,
+ 146, 60, 146, 489, 270, 407, 165, 178, 60, 302,
+ 60, 0, 89, 330, 168, 288, 60, 60, 60, 60,
+ 0, 287, 286, 284, 285, 471, 60, 60, 432, 180,
+ 435, 60, 60, 452, 72, 60, 60, 451, 96, 60,
+ 480, 494, 77, 500, 479, 329, 60, 334, 305, 61,
+ 612, 60, 60, 69, 68, 60, 404, 60, 70, 67,
+ 60, 60, 490, 60, 60, 493, 84, 404, 60, 341,
+ 492, 60, 60, 180, 303, 60, 100, 60, 98, 491,
+ 91, 60, 0, 298, 405, 60, 106, 97, 270, 0,
+ 270, 500, 298, 500, 60, 405, 605, 270, 293, 270,
+ 602, 0, 0, 0, 0, 317, 499, 509, 108, 175,
+ 60, 316, 0, 60, 319, 270, 60, 290, 270, 298,
+ 289, 270, 0, 291, 270, 298, 60, 60, 0, 60,
+ 270, 270, 270, 500, 270, 0, 637, 295, 273, 298,
+ 602, 297, 313, 60, 270, 611, 0, 300, 270, 599,
+ 278, 302, 601, 500, 0, 567, 602, 0, 0, 0,
+ 0, 326, 570, 563, 564, 565, 566, 0, 499, 509,
+ 0, 472, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 128, 0, 0, 0, 0, 0, 0,
- 47, 49, 48, 129, 130, 131, 0, 133, 134, 135,
- 136, 137, 138, 0, 0, 126, 132, 118, 111, 113,
- 127, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 108, 109, 110, 0, 0, 112,
- 114, 115, 0, 0, 116, 0, 117, 0, 0, 0,
- 119, 120, 121, 0, 0, 0, 0, 0, 0, 392,
- 122, 123, 124, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 125, 0, 0, 0, 393, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 128,
- 0, 0, 0, 0, 0, 397, 394, 396, 0, 129,
- 130, 131, 0, 133, 134, 135, 136, 137, 138, 0,
- 0, 126, 132, 118, 111, 113, 127, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 108, 109, 110, 0, 0, 112, 114, 115, 0, 0,
- 116, 0, 117, 0, 0, 0, 119, 120, 121, 0,
- 0, 0, 0, 0, 0, 392, 122, 123, 124, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 125,
- 0, 0, 0, 393, 0, 0, 0, 0, 0, 0,
- 0, 395, 0, 0, 0, 128, 0, 0, 0, 0,
- 0, 397, 394, 396, 0, 129, 130, 131, 0, 133,
- 134, 135, 136, 137, 138, 0, 0, 126, 132, 118,
- 111, 113, 127, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 208, 0, 0, 0,
- 0, 210, 0, 29, 30, 31, 212, 0, 0, 0,
- 0, 0, 0, 213, 33, 0, 0, 0, 0, 0,
- 0, 215, 216, 0, 0, 217, 36, 0, 37, 0,
- 0, 0, 38, 0, 39, 41, 42, 0, 0, 44,
- 0, 0, 0, 45, 0, 46, 0, 0, 0, 0,
- 0, 219, 0, 220, 0, 0, 0, 50, 218, 221,
- 48, 222, 51, 223, 52, 224, 54, 225, 55, 226,
- 227, 0, 0, 43, 53, 32, 209, 211, 0, 40,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 208, 0, 0, 0, 0, 210, 0, 29,
- 30, 31, 212, 0, 0, 0, 0, 0, 0, 213,
- 214, 0, 0, 0, 0, 0, 0, 215, 216, 0,
- 0, 217, 36, 0, 37, 0, 0, 0, 38, 0,
- 39, 41, 42, 0, 0, 44, 0, 0, 0, 45,
- 0, 46, 0, 0, 0, 0, 0, 219, 0, 220,
- 0, 0, 0, 50, 218, 221, 48, 222, 51, 223,
- 52, 224, 54, 225, 55, 226, 227, 0, 0, 43,
- 53, 32, 209, 211, 0, 40, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 569, 109,
- 110, 0, 0, 571, 114, 573, 30, 31, 574, 0,
- 117, 0, 0, 0, 119, 576, 577, 0, 0, 0,
- 0, 0, 0, 578, 579, 123, 124, 217, 36, 0,
- 37, 0, 0, 0, 38, 0, 39, 580, 42, 0,
- 0, 582, 0, 0, 0, 45, 0, 46, 0, 0,
- 0, 0, 0, 584, 0, 220, 0, 0, 0, 586,
- 583, 585, 48, 587, 588, 589, 52, 591, 592, 593,
- 594, 595, 596, 0, 0, 581, 590, 575, 570, 572,
- 127, 40, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 360, 109, 110, 0, 0, 362,
- 114, 364, 30, 31, 365, 0, 117, 0, 0, 0,
- 119, 367, 368, 0, 0, 0, 0, 0, 0, 369,
- 370, 123, 124, 217, 36, 0, 37, 0, 0, 0,
- 38, 0, 39, 371, 42, 0, 0, 373, 0, 0,
- 0, 45, 0, 46, 0, -263, 0, 0, 0, 375,
- 0, 220, 0, 0, 0, 377, 374, 376, 48, 378,
- 379, 380, 52, 382, 383, 384, 385, 386, 387, 0,
- 0, 372, 381, 366, 361, 363, 127, 40, 0, 0,
+ 0, 0, 0, 0, 0, 0, 332, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
-
- 541, 310, 460, 513, 538, 518, 525, 308, 249, 632,
- 306, 181, 252, 618, 149, 16, 623, 495, 319, 497,
- 629, 357, 496, 435, 471, 553, 557, 486, 438, 301,
- 428, 237, 350, 352, 604, 521, 242, 424, 550, 552,
- 181, 301, 185, 237, 242, 343, 432, 348, 338, 249,
- 459, 237, 453, 449, 236, 242, 446, 181, 466, 401,
- 448, 249, 357, 455, 444, 457, 346, 337, 357, 484,
- 142, 236, 147, 333, 438, 175, 301, 335, 187, 409,
- 162, 145, 435, 416, 435, 139, 170, 399, 414, 481,
- 438, 389, 0, 168, 0, 0, 403, 357, 403, 59,
- 357, 490, 301, 534, 391, 0, 0, 0, 301, 0,
- 0, 460, 0, 145, 59, 0, 179, 403, 177, 59,
- 59, 488, 489, 0, 404, 105, 404, 0, 59, 185,
- 451, 59, 59, 450, 59, 59, 59, 59, 59, 283,
- 284, 59, 287, 285, 145, 404, 286, 107, 167, 406,
- 164, 59, 59, 451, 450, 265, 59, 59, 301, 59,
- 269, 68, 96, 95, 479, 59, 59, 331, 478, 59,
- 87, 76, 59, 329, 59, 97, 434, 83, 89, 431,
- 59, 470, 59, 59, 59, 94, 88, 59, 93, 92,
- 59, 59, 90, 59, 59, 91, 493, 59, 59, 71,
- 67, 59, 59, 491, 492, 99, 59, 101, 179, 319,
- 301, 59, 59, 340, 69, 60, 59, 59, 450, 66,
- 59, 59, 451, 304, 105, 499, 269, 297, 297, 297,
- 59, 59, 269, 269, 269, 269, 269, 0, 315, 272,
- 498, 508, 294, 0, 0, 0, 107, 174, 59, 325,
- 318, 316, 297, 269, 59, 290, 0, 269, 297, 269,
- 0, 59, 0, 269, 59, 0, 269, 292, 59, 269,
- 179, 277, 59, 0, 299, 302, 312, 269, 59, 288,
- 296, 328, 609, 269, 499, 289, 597, 633, 606, 599,
- 499, 600, 565, 600, 0, 0, 499, 0, 0, 568,
- 561, 562, 563, 564, 0, 498, 508, 0, 471, 0,
- 0, 498, 508, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 499, 0, 0, 603, 0, 0, 0, 600, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 608, 0, 0, 0, 0, 0,
+ 0, 0, 500, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 499, 509, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
@@ -636,148 +663,174 @@ const short QDeclarativeJSGrammar::action_info [] = {
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0};
+ 0, 0, 0, 0, 0};
const short QDeclarativeJSGrammar::action_check [] = {
- 7, 7, 36, 90, 7, 29, 36, 7, 36, 7,
- 33, 8, 7, 7, 36, 7, 90, 7, 0, 7,
- 16, 60, 55, 33, 8, 29, 7, 36, 7, 55,
- 79, 48, 1, 7, 55, 2, 7, 17, 37, 7,
- 33, 60, 29, 7, 33, 7, 66, 33, 33, 7,
- 66, 29, 7, 36, 20, 7, 7, 29, 33, 36,
- 36, 24, 5, 36, 5, 7, 36, 5, 1, 60,
- 7, 36, 7, 2, 79, 2, 33, 8, 8, 7,
- 1, 7, 36, 36, 8, 1, 36, -1, 8, 36,
- -1, 2, 36, 8, 55, 7, -1, -1, -1, 17,
- 60, 60, 48, 48, 60, 7, -1, 55, 8, -1,
- 33, 36, 61, 6, 48, -1, 33, 15, 8, 10,
- 8, 60, 36, 36, 7, 8, 8, 20, 8, 61,
- 8, 33, 8, -1, 8, 40, 34, 77, 60, 8,
- 8, 8, 61, 79, 50, -1, 51, 50, 54, 8,
- 60, 54, 61, 62, 61, 62, 56, 61, 62, 40,
- 61, 62, 61, 62, 55, 40, 56, 61, 62, 12,
- 51, 42, 60, 15, 61, 62, 51, 7, 60, -1,
- 60, 8, 53, 61, 60, 31, 60, 40, 56, 61,
- 62, 60, 34, 60, 29, 61, 62, 56, 51, 61,
- 62, 61, 62, 25, 25, 27, 27, 8, 25, 25,
- 27, 27, 12, 25, 57, 27, 38, 38, 29, 29,
- 63, 38, 38, 25, 15, 27, 38, 12, 25, -1,
- 27, 61, 62, 8, 61, 62, 38, 25, 8, 27,
- 75, 38, 25, 34, 27, 36, 25, 15, 27, 8,
- 38, 86, 61, 62, 8, 38, 25, 57, 27, 38,
- 61, 62, 15, 63, 75, 75, 34, 29, 36, 38,
- 36, 29, 57, 8, 29, 86, 86, 25, 63, 27,
- 7, 34, 91, 36, 29, -1, 61, 62, -1, -1,
- 38, 61, 62, -1, -1, 61, 62, 25, -1, 27,
- 47, -1, 61, 62, 29, -1, 60, -1, -1, -1,
- 38, 18, 19, 75, 61, 62, 29, 75, -1, 29,
- 75, 66, 67, 68, 86, -1, 61, 62, 86, 15,
- -1, 86, 29, -1, 61, 62, 18, 19, 45, 46,
- 29, 66, 67, 68, 91, 29, 15, 33, 34, 29,
- 36, -1, 29, 66, 67, 68, 66, 67, 68, 29,
- -1, -1, 29, 45, 46, 34, 29, 36, -1, 66,
- 67, 68, 29, -1, 15, 29, -1, 66, 67, 68,
- -1, -1, 66, 67, 68, -1, 66, 67, 68, 66,
- 67, 68, 33, 34, -1, 36, 66, 67, 68, 66,
- 67, 68, -1, 66, 67, 68, 23, 24, -1, 66,
- 67, 68, 66, 67, 68, 32, 23, 24, 35, -1,
- 37, -1, -1, 29, -1, 32, 29, -1, 35, 29,
- 37, 18, 19, 36, 23, 24, 36, 29, -1, -1,
- -1, -1, -1, 32, -1, -1, 35, -1, 37, 29,
- -1, -1, -1, -1, -1, 61, 62, -1, 45, 46,
- 66, 67, 68, 66, 67, 68, 66, 67, 68, 61,
- 62, 23, 24, 29, 66, 67, 68, -1, -1, 31,
- 32, 61, 62, 35, -1, 37, 66, 67, 68, 23,
- 24, 29, -1, -1, -1, -1, -1, 31, 32, -1,
- -1, 35, -1, 37, -1, 61, 62, 23, 24, 29,
- 66, 67, 68, 23, 24, 31, 32, -1, -1, 35,
- -1, 37, 32, 61, 62, 35, -1, 37, 66, 67,
- 68, 92, 93, 94, 95, 96, 97, -1, -1, 3,
- -1, 61, 62, -1, -1, -1, 66, 67, 68, 13,
- -1, -1, -1, 17, -1, -1, -1, 3, -1, -1,
- -1, -1, 26, -1, 28, -1, -1, 13, -1, -1,
- -1, 17, -1, -1, -1, 39, -1, 41, 42, -1,
- 26, -1, 28, -1, -1, 49, -1, -1, 52, 53,
- 23, 24, -1, 39, 58, 41, 42, -1, 31, 32,
- 64, -1, 35, 49, 37, -1, 52, 53, -1, -1,
- -1, -1, 58, -1, -1, -1, 80, -1, 64, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 12,
- 13, -1, -1, -1, 80, -1, -1, -1, -1, 22,
- -1, -1, -1, -1, -1, -1, 29, -1, -1, -1,
- 33, 34, -1, 36, -1, -1, -1, -1, -1, -1,
- 43, -1, -1, -1, 47, -1, -1, 3, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 13, -1, -1,
- -1, 17, 65, 66, 67, 68, -1, 70, -1, -1,
- 26, -1, 28, -1, -1, 31, -1, -1, 81, 82,
- 83, -1, -1, 39, 87, 41, 42, -1, -1, -1,
- -1, -1, -1, 49, -1, -1, 52, 53, -1, -1,
- -1, -1, 58, -1, -1, -1, -1, -1, 64, -1,
+ 55, 7, 33, 7, 55, 7, 60, 36, 90, 55,
+ 7, 16, 36, 7, 7, 7, 7, 36, 7, 60,
+ 36, 8, 33, 66, 36, 33, 60, 36, 7, 36,
+ 7, 7, 33, 36, 24, 7, 7, 37, 8, 60,
+ 66, 29, 17, 5, 7, 60, 7, 33, 33, 33,
+ 7, 20, 33, 36, 7, 7, 36, 7, 36, 33,
+ 7, 17, 60, 36, 1, 33, 79, 2, 8, 7,
+ 36, 1, 8, 55, 7, 2, 8, 2, 7, 7,
+ 79, 36, 77, 79, 48, 36, 7, 36, 55, 48,
+ 36, 36, 33, 36, 8, 60, 1, 31, 0, 2,
+ 8, 61, 60, 1, 48, 6, 10, 61, 7, 8,
+ -1, 8, 8, 61, 8, -1, -1, 48, 40, 20,
+ 8, 60, 8, 42, -1, 40, -1, 50, 8, 51,
+ 8, 54, 8, 15, 53, 8, 51, 61, 62, 8,
+ 5, 61, 62, 61, 62, 61, 62, 40, 90, 61,
+ 62, 55, 34, 79, 61, 62, 40, 8, 51, 8,
+ 8, 61, 62, 60, 60, 50, 60, 51, 56, 54,
+ 56, 61, 62, 8, 61, 62, 56, 15, 61, 62,
+ 61, 62, 60, 56, 60, 15, 25, 8, 27, 29,
+ 7, 60, 25, 29, 27, 7, 34, 12, 36, 38,
+ 25, 25, 27, 27, 34, 38, 36, 12, 8, 12,
+ 61, 60, 60, 38, 38, 8, 25, 25, 27, 27,
+ -1, 33, 7, -1, -1, 29, 61, 62, 29, 38,
+ 38, -1, 29, 8, -1, 75, 15, 8, 36, 75,
+ 61, 62, 57, -1, 61, 62, 86, 29, 63, -1,
+ 86, 15, 57, -1, 57, 34, 18, 19, 63, -1,
+ 63, 61, 62, 61, 62, 61, 62, -1, 61, 62,
+ 34, 75, 36, 15, 75, -1, 61, 62, 75, 15,
+ 92, -1, 86, 45, 46, 86, 61, 62, 29, 86,
+ 61, 62, 34, 75, 36, 91, 47, 33, 34, 15,
+ 36, 18, 19, -1, 86, 18, 19, 29, -1, -1,
+ 61, 62, -1, -1, 18, 19, -1, 33, 34, 29,
+ 36, -1, 25, 29, 27, 66, 67, 68, 45, 46,
+ -1, -1, 45, 46, -1, 38, -1, -1, 23, 24,
+ 91, 45, 46, -1, 66, 67, 68, 32, -1, -1,
+ 35, 92, 37, 29, 23, 24, 66, 67, 68, -1,
+ 66, 67, 68, 32, 23, 24, 35, 29, 37, -1,
+ 92, 23, 24, 32, 36, -1, 35, -1, 37, -1,
+ 32, 29, 92, 35, -1, 37, 92, 23, 24, 29,
+ 66, 67, 68, -1, -1, 29, 32, -1, 29, 35,
+ -1, 37, 36, -1, 66, 67, 68, 93, 94, 95,
+ 96, 97, 98, 61, 62, -1, 92, 29, 66, 67,
+ 68, 61, 62, -1, -1, -1, 66, 67, 68, -1,
+ 92, -1, 66, 67, 68, 66, 67, 68, -1, -1,
+ -1, -1, -1, -1, 92, -1, -1, -1, -1, 61,
+ 62, -1, 92, 29, 66, 67, 68, -1, 92, -1,
+ -1, 92, 29, -1, -1, 29, -1, -1, -1, -1,
+ 23, 24, -1, -1, -1, -1, -1, -1, 31, 32,
+ 92, -1, 35, -1, 37, 61, 62, -1, -1, -1,
+ 66, 67, 68, -1, 61, 62, -1, 61, 62, 66,
+ 67, 68, 66, 67, 68, -1, -1, -1, -1, -1,
+ 12, 13, -1, -1, -1, -1, 92, -1, -1, -1,
+ 22, -1, -1, -1, -1, 92, -1, 29, 92, -1,
+ -1, 33, 34, -1, 36, -1, -1, -1, -1, -1,
+ -1, 43, -1, -1, -1, 47, -1, -1, 3, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 13, -1,
+ -1, -1, 17, 65, 66, 67, 68, -1, 70, -1,
+ -1, 26, -1, 28, -1, -1, -1, -1, -1, 81,
+ 82, 83, -1, -1, 39, 87, 41, 42, -1, -1,
+ 92, -1, -1, -1, 49, 12, 13, 52, 53, -1,
+ -1, -1, -1, 58, -1, 22, -1, -1, -1, 64,
+ -1, -1, 29, -1, -1, -1, 33, 34, -1, 36,
+ -1, -1, -1, -1, -1, 80, 43, -1, -1, -1,
+ 47, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 3, -1, 65, 66,
+ 67, 68, -1, 70, -1, -1, 13, -1, -1, -1,
+ 17, -1, -1, -1, 81, 82, 83, -1, -1, 26,
+ 87, 28, -1, -1, 31, 92, -1, -1, -1, -1,
+ -1, -1, 39, -1, 41, 42, -1, -1, -1, -1,
+ -1, -1, 49, -1, -1, 52, 53, -1, -1, -1,
+ -1, 58, -1, -1, -1, -1, -1, 64, -1, -1,
-1, -1, -1, -1, -1, -1, 12, 13, -1, -1,
- -1, -1, -1, -1, 80, -1, 22, -1, -1, -1,
+ -1, -1, -1, 80, -1, -1, 22, -1, -1, -1,
-1, -1, -1, 29, -1, -1, -1, 33, 34, -1,
36, -1, -1, -1, 12, 13, -1, 43, -1, -1,
-1, 47, -1, -1, 22, -1, -1, -1, -1, -1,
-1, 29, -1, -1, -1, 33, 34, -1, 36, 65,
66, 67, 68, -1, 70, 43, -1, -1, -1, 47,
-1, -1, -1, -1, -1, 81, 82, 83, -1, -1,
- -1, 87, -1, -1, -1, -1, -1, 65, 66, 67,
- 68, -1, 70, -1, 10, -1, 12, 13, -1, -1,
- -1, -1, -1, 81, 82, 83, 22, -1, -1, 87,
- -1, -1, -1, 29, -1, -1, -1, 33, 34, -1,
- 36, -1, 12, 13, -1, -1, -1, 43, -1, -1,
- -1, 47, 22, -1, -1, -1, -1, -1, -1, 29,
- -1, -1, -1, 33, 34, -1, 36, -1, -1, 65,
- 66, 67, 68, 43, 70, -1, -1, 47, -1, 75,
- -1, -1, -1, -1, -1, 81, 82, 83, 84, -1,
- -1, 87, -1, -1, -1, 65, 66, 67, 68, -1,
- 70, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 81, 82, 83, -1, -1, -1, 87, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 10, -1, 12, 13, -1, -1, -1, -1, -1, -1,
- -1, -1, 22, -1, -1, -1, -1, -1, -1, 29,
- -1, -1, -1, 33, 34, -1, 36, -1, -1, -1,
- -1, -1, -1, 43, -1, -1, -1, 47, -1, -1,
- -1, -1, -1, -1, -1, 55, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 65, 66, 67, 68, -1,
- 70, -1, -1, -1, -1, 75, -1, -1, -1, -1,
- -1, 81, 82, 83, 84, -1, -1, 87, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 10, -1, 12, 13, -1, -1, -1, -1, -1, -1,
- -1, -1, 22, -1, -1, -1, -1, -1, -1, 29,
- -1, -1, -1, 33, 34, -1, 36, -1, -1, -1,
+ -1, 87, -1, -1, -1, -1, 92, 65, 66, 67,
+ 68, -1, 70, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 81, 82, 83, -1, -1, -1, 87,
+ -1, -1, -1, -1, 92, 12, 13, -1, -1, -1,
+ -1, -1, -1, 12, 13, 22, -1, -1, -1, -1,
+ -1, -1, 29, 22, -1, -1, 33, 34, -1, 36,
+ 29, -1, -1, -1, 33, 34, 43, 36, -1, -1,
+ 47, -1, -1, -1, 43, -1, -1, -1, 47, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 65, 66,
+ 67, 68, -1, 70, -1, -1, 65, 66, 67, 68,
+ -1, 70, -1, -1, 81, 82, 83, -1, -1, -1,
+ 87, -1, 81, 82, 83, 92, -1, -1, 87, -1,
+ -1, -1, -1, 92, 12, 13, -1, -1, -1, -1,
+ -1, -1, 12, 13, 22, -1, -1, -1, -1, -1,
+ -1, 29, 22, -1, -1, 33, 34, -1, 36, 29,
+ -1, -1, -1, 33, 34, 43, 36, -1, -1, 47,
-1, -1, -1, 43, -1, -1, -1, 47, -1, -1,
- -1, -1, -1, -1, -1, 55, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 65, 66, 67, 68, -1,
- 70, -1, -1, -1, -1, 75, -1, -1, -1, -1,
- -1, 81, 82, 83, 84, -1, -1, 87, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 11, 12, 13, -1, -1, -1, -1, -1, -1, -1,
- -1, 22, -1, -1, -1, -1, -1, -1, 29, -1,
- -1, -1, 33, 34, -1, 36, -1, -1, -1, 40,
- -1, 42, 43, 44, -1, -1, 47, -1, -1, -1,
- 51, -1, 53, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 65, 66, 67, 68, -1, 70,
- -1, 72, -1, 74, -1, 76, -1, -1, -1, -1,
- 81, 82, 83, -1, -1, -1, 87, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 7,
- -1, -1, -1, 11, 12, 13, -1, -1, -1, -1,
- -1, -1, -1, -1, 22, -1, -1, -1, -1, -1,
- -1, 29, -1, -1, -1, 33, 34, -1, 36, -1,
- -1, -1, 40, -1, 42, 43, 44, -1, -1, 47,
- -1, -1, -1, 51, -1, 53, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, 65, 66, 67,
- 68, -1, 70, -1, 72, -1, 74, -1, 76, -1,
- -1, -1, -1, 81, 82, 83, -1, -1, -1, 87,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 11, 12, 13, -1, -1, -1, -1, -1,
+ 68, -1, 70, -1, -1, 65, 66, 67, 68, -1,
+ 70, -1, -1, 81, 82, 83, -1, -1, -1, 87,
+ -1, 81, 82, 83, 92, -1, -1, 87, -1, -1,
+ -1, -1, 92, -1, -1, -1, -1, -1, -1, -1,
+ -1, 10, -1, 12, 13, -1, -1, -1, -1, -1,
-1, -1, -1, 22, -1, -1, -1, -1, -1, -1,
29, -1, -1, -1, 33, 34, -1, 36, -1, -1,
- -1, 40, -1, 42, 43, 44, -1, -1, 47, -1,
- -1, -1, 51, -1, 53, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 65, 66, 67, 68,
- -1, 70, -1, 72, -1, 74, 75, 76, -1, -1,
- -1, -1, 81, 82, 83, -1, -1, -1, 87, -1,
+ -1, -1, -1, -1, 43, -1, -1, -1, 47, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 65, 66, 67, 68,
+ -1, 70, -1, -1, -1, -1, 75, -1, -1, -1,
+ -1, -1, 81, 82, 83, 84, -1, -1, 87, -1,
+ -1, -1, -1, 92, -1, -1, -1, -1, -1, -1,
+ -1, -1, 10, -1, 12, 13, -1, -1, -1, -1,
+ -1, -1, -1, -1, 22, -1, -1, -1, -1, -1,
+ -1, 29, -1, -1, -1, 33, 34, -1, 36, -1,
+ -1, -1, -1, -1, -1, 43, -1, -1, -1, 47,
+ -1, -1, -1, -1, -1, -1, -1, 55, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 65, 66, 67,
+ 68, -1, 70, -1, -1, -1, -1, 75, -1, -1,
+ -1, -1, -1, 81, 82, 83, 84, -1, -1, 87,
+ -1, -1, -1, -1, 92, -1, -1, -1, -1, -1,
+ -1, -1, -1, 10, -1, 12, 13, -1, -1, -1,
+ -1, -1, -1, -1, -1, 22, -1, -1, -1, -1,
+ -1, -1, 29, -1, -1, -1, 33, 34, -1, 36,
+ -1, -1, -1, -1, -1, -1, 43, -1, -1, -1,
+ 47, -1, -1, -1, -1, -1, -1, -1, 55, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 65, 66,
+ 67, 68, -1, 70, -1, -1, -1, -1, 75, -1,
+ -1, -1, -1, -1, 81, 82, 83, 84, -1, -1,
+ 87, -1, -1, -1, -1, 92, -1, -1, -1, -1,
+ -1, -1, -1, -1, 11, 12, 13, -1, -1, -1,
+ -1, -1, -1, -1, -1, 22, -1, -1, -1, -1,
+ -1, -1, 29, -1, -1, -1, 33, 34, -1, 36,
+ -1, -1, -1, 40, -1, 42, 43, 44, -1, -1,
+ 47, -1, -1, -1, 51, -1, 53, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 65, 66,
+ 67, 68, -1, 70, -1, 72, -1, 74, -1, 76,
+ -1, -1, -1, -1, 81, 82, 83, -1, -1, -1,
+ 87, -1, -1, -1, -1, 92, -1, -1, -1, -1,
+ -1, -1, -1, -1, 7, -1, -1, -1, 11, 12,
+ 13, -1, -1, -1, -1, -1, -1, -1, -1, 22,
+ -1, -1, -1, -1, -1, -1, 29, -1, -1, -1,
+ 33, 34, -1, 36, -1, -1, -1, 40, -1, 42,
+ 43, 44, -1, -1, 47, -1, -1, -1, 51, -1,
+ 53, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 65, 66, 67, 68, -1, 70, -1, 72,
+ -1, 74, -1, 76, -1, -1, -1, -1, 81, 82,
+ 83, -1, -1, -1, 87, -1, -1, -1, -1, 92,
+ -1, -1, -1, -1, -1, -1, -1, -1, 11, 12,
+ 13, -1, -1, -1, -1, -1, -1, -1, -1, 22,
+ -1, -1, -1, -1, -1, -1, 29, -1, -1, -1,
+ 33, 34, -1, 36, -1, -1, -1, 40, -1, 42,
+ 43, 44, -1, -1, 47, -1, -1, -1, 51, -1,
+ 53, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 65, 66, 67, 68, -1, 70, -1, 72,
+ -1, 74, 75, 76, -1, -1, -1, -1, 81, 82,
+ 83, -1, -1, -1, 87, -1, -1, -1, -1, 92,
+ -1, -1, -1, -1, -1, -1, -1, -1, 8, -1,
+ -1, 11, 12, 13, -1, -1, -1, -1, -1, -1,
+ -1, -1, 22, -1, -1, -1, -1, -1, -1, 29,
+ -1, -1, -1, 33, 34, -1, 36, -1, -1, -1,
+ 40, -1, 42, 43, 44, -1, -1, 47, -1, -1,
+ -1, 51, -1, 53, -1, -1, 56, -1, -1, -1,
+ -1, -1, -1, -1, -1, 65, 66, 67, 68, -1,
+ 70, -1, 72, -1, 74, -1, 76, -1, -1, -1,
+ -1, 81, 82, 83, -1, -1, -1, 87, -1, -1,
+ -1, -1, 92, -1, -1, -1, -1, -1, -1, -1,
-1, 11, 12, 13, -1, -1, -1, -1, -1, -1,
-1, -1, 22, -1, -1, -1, -1, -1, -1, 29,
30, -1, -1, 33, 34, -1, 36, -1, -1, -1,
@@ -786,25 +839,16 @@ const short QDeclarativeJSGrammar::action_check [] = {
-1, 61, -1, -1, -1, 65, 66, 67, 68, -1,
70, -1, 72, -1, 74, -1, 76, -1, -1, -1,
-1, 81, 82, 83, -1, -1, -1, 87, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 8, -1, -1, 11, 12, 13, -1, -1, -1, -1,
- -1, -1, -1, -1, 22, -1, -1, -1, -1, -1,
- -1, 29, -1, -1, -1, 33, 34, -1, 36, -1,
- -1, -1, 40, -1, 42, 43, 44, -1, -1, 47,
- -1, -1, -1, 51, -1, 53, -1, -1, 56, -1,
- -1, -1, -1, -1, -1, -1, -1, 65, 66, 67,
- 68, -1, 70, -1, 72, -1, 74, -1, 76, -1,
- -1, -1, -1, 81, 82, 83, -1, -1, -1, 87,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 8, -1, -1, 11, 12, 13, -1, -1,
- -1, -1, -1, -1, -1, -1, 22, -1, -1, -1,
- -1, -1, -1, 29, -1, -1, -1, 33, 34, -1,
- 36, -1, -1, -1, 40, -1, 42, 43, 44, -1,
- -1, 47, -1, -1, -1, 51, -1, 53, -1, -1,
- 56, -1, -1, -1, -1, -1, -1, -1, -1, 65,
- 66, 67, 68, -1, 70, -1, 72, -1, 74, -1,
- 76, -1, -1, -1, -1, 81, 82, 83, -1, -1,
- -1, 87, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 92, -1, -1, -1, -1, -1, -1, -1,
+ -1, 8, -1, -1, 11, 12, 13, -1, -1, -1,
+ -1, -1, -1, -1, -1, 22, -1, -1, -1, -1,
+ -1, -1, 29, -1, -1, -1, 33, 34, -1, 36,
+ -1, -1, -1, 40, -1, 42, 43, 44, -1, -1,
+ 47, -1, -1, -1, 51, -1, 53, -1, -1, 56,
+ -1, -1, -1, -1, -1, -1, -1, -1, 65, 66,
+ 67, 68, -1, 70, -1, 72, -1, 74, -1, 76,
+ -1, -1, -1, -1, 81, 82, 83, -1, -1, -1,
+ 87, -1, -1, -1, -1, 92, -1, -1, -1, -1,
-1, -1, -1, -1, 8, -1, -1, 11, 12, 13,
-1, -1, -1, -1, -1, -1, -1, -1, 22, -1,
-1, -1, -1, -1, -1, 29, -1, -1, -1, 33,
@@ -813,120 +857,129 @@ const short QDeclarativeJSGrammar::action_check [] = {
-1, -1, 56, -1, -1, -1, -1, -1, -1, -1,
-1, 65, 66, 67, 68, -1, 70, -1, 72, -1,
74, -1, 76, -1, -1, -1, -1, 81, 82, 83,
- -1, -1, -1, 87, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 8, -1, -1, 11,
- 12, 13, -1, -1, -1, -1, -1, -1, -1, -1,
- 22, -1, -1, -1, -1, -1, -1, 29, -1, -1,
- -1, 33, 34, -1, 36, -1, -1, -1, 40, -1,
- 42, 43, 44, -1, -1, 47, -1, -1, -1, 51,
- -1, 53, -1, -1, 56, -1, -1, -1, -1, -1,
- -1, -1, -1, 65, 66, 67, 68, -1, 70, -1,
- 72, -1, 74, -1, 76, -1, -1, -1, -1, 81,
- 82, 83, -1, -1, -1, 87, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 4, 5,
- 6, -1, -1, 9, 10, 11, -1, -1, 14, -1,
- 16, -1, -1, -1, 20, 21, 22, -1, -1, -1,
- -1, -1, -1, 29, 30, 31, 32, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 43, -1, -1,
+ -1, -1, -1, 87, -1, -1, -1, -1, 92, -1,
+ -1, -1, -1, -1, -1, -1, -1, 8, -1, -1,
+ 11, 12, 13, -1, -1, -1, -1, -1, -1, -1,
+ -1, 22, -1, -1, -1, -1, -1, -1, 29, -1,
+ -1, -1, 33, 34, -1, 36, -1, -1, -1, 40,
+ -1, 42, 43, 44, -1, -1, 47, -1, -1, -1,
+ 51, -1, 53, -1, -1, 56, -1, -1, -1, -1,
+ -1, -1, -1, -1, 65, 66, 67, 68, -1, 70,
+ -1, 72, -1, 74, -1, 76, -1, -1, -1, -1,
+ 81, 82, 83, -1, -1, -1, 87, -1, -1, -1,
+ -1, 92, -1, -1, -1, -1, -1, -1, -1, -1,
+ 4, 5, 6, -1, -1, 9, 10, 11, -1, -1,
+ 14, -1, 16, -1, -1, -1, 20, 21, 22, -1,
+ -1, -1, -1, -1, -1, 29, 30, 31, 32, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 43,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 59, -1, -1, -1, -1,
+ -1, -1, 66, 67, 68, 69, 70, 71, -1, 73,
+ 74, 75, 76, 77, 78, -1, -1, 81, 82, 83,
+ 84, 85, 86, -1, -1, -1, -1, -1, 92, -1,
+ -1, -1, -1, -1, -1, -1, -1, 4, 5, 6,
+ -1, -1, 9, 10, 11, -1, -1, 14, -1, 16,
+ -1, -1, -1, 20, 21, 22, -1, -1, -1, -1,
+ -1, -1, 29, 30, 31, 32, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 43, -1, -1, -1,
+ 47, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 59, -1, -1, -1, -1, -1, 65, 66,
+ 67, -1, 69, 70, 71, -1, 73, 74, 75, 76,
+ 77, 78, -1, -1, 81, 82, 83, 84, 85, 86,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 59, -1, -1, -1, -1, -1, -1,
- 66, 67, 68, 69, 70, 71, -1, 73, 74, 75,
- 76, 77, 78, -1, -1, 81, 82, 83, 84, 85,
- 86, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, 4, 5, 6, -1, -1, 9,
10, 11, -1, -1, 14, -1, 16, -1, -1, -1,
20, 21, 22, -1, -1, -1, -1, -1, -1, 29,
30, 31, 32, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, 43, -1, -1, -1, 47, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 59,
+ -1, -1, -1, -1, -1, 55, -1, -1, -1, 59,
-1, -1, -1, -1, -1, 65, 66, 67, -1, 69,
70, 71, -1, 73, 74, 75, 76, 77, 78, -1,
-1, 81, 82, 83, 84, 85, 86, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 4, 5, 6, -1, -1, 9, 10, 11, -1, -1,
- 14, -1, 16, -1, -1, -1, 20, 21, 22, -1,
- -1, -1, -1, -1, -1, 29, 30, 31, 32, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 43,
- -1, -1, -1, 47, -1, -1, -1, -1, -1, -1,
- -1, 55, -1, -1, -1, 59, -1, -1, -1, -1,
- -1, 65, 66, 67, -1, 69, 70, 71, -1, 73,
- 74, 75, 76, 77, 78, -1, -1, 81, 82, 83,
- 84, 85, 86, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 4, -1, -1, -1,
- -1, 9, -1, 11, 12, 13, 14, -1, -1, -1,
- -1, -1, -1, 21, 22, -1, -1, -1, -1, -1,
- -1, 29, 30, -1, -1, 33, 34, -1, 36, -1,
- -1, -1, 40, -1, 42, 43, 44, -1, -1, 47,
- -1, -1, -1, 51, -1, 53, -1, -1, -1, -1,
- -1, 59, -1, 61, -1, -1, -1, 65, 66, 67,
- 68, 69, 70, 71, 72, 73, 74, 75, 76, 77,
- 78, -1, -1, 81, 82, 83, 84, 85, -1, 87,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 4, -1, -1, -1, -1, 9, -1, 11,
- 12, 13, 14, -1, -1, -1, -1, -1, -1, 21,
- 22, -1, -1, -1, -1, -1, -1, 29, 30, -1,
- -1, 33, 34, -1, 36, -1, -1, -1, 40, -1,
- 42, 43, 44, -1, -1, 47, -1, -1, -1, 51,
- -1, 53, -1, -1, -1, -1, -1, 59, -1, 61,
- -1, -1, -1, 65, 66, 67, 68, 69, 70, 71,
- 72, 73, 74, 75, 76, 77, 78, -1, -1, 81,
- 82, 83, 84, 85, -1, 87, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 4, 5,
- 6, -1, -1, 9, 10, 11, 12, 13, 14, -1,
- 16, -1, -1, -1, 20, 21, 22, -1, -1, -1,
- -1, -1, -1, 29, 30, 31, 32, 33, 34, -1,
+ -1, 4, -1, -1, -1, -1, 9, -1, 11, 12,
+ 13, 14, -1, -1, -1, -1, -1, -1, 21, 22,
+ -1, -1, -1, -1, -1, -1, 29, 30, -1, -1,
+ 33, 34, -1, 36, -1, -1, -1, 40, -1, 42,
+ 43, 44, -1, -1, 47, -1, -1, -1, 51, -1,
+ 53, -1, -1, -1, -1, -1, 59, -1, 61, -1,
+ -1, -1, 65, 66, 67, 68, 69, 70, 71, 72,
+ 73, 74, 75, 76, 77, 78, -1, -1, 81, 82,
+ 83, 84, 85, -1, 87, -1, -1, -1, -1, 92,
+ -1, -1, -1, -1, -1, -1, -1, -1, 4, -1,
+ -1, -1, -1, 9, -1, 11, 12, 13, 14, -1,
+ -1, -1, -1, -1, -1, 21, 22, -1, -1, -1,
+ -1, -1, -1, 29, 30, -1, -1, 33, 34, -1,
36, -1, -1, -1, 40, -1, 42, 43, 44, -1,
-1, 47, -1, -1, -1, 51, -1, 53, -1, -1,
-1, -1, -1, 59, -1, 61, -1, -1, -1, 65,
66, 67, 68, 69, 70, 71, 72, 73, 74, 75,
76, 77, 78, -1, -1, 81, 82, 83, 84, 85,
- 86, 87, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 4, 5, 6, -1, -1, 9,
- 10, 11, 12, 13, 14, -1, 16, -1, -1, -1,
- 20, 21, 22, -1, -1, -1, -1, -1, -1, 29,
- 30, 31, 32, 33, 34, -1, 36, -1, -1, -1,
- 40, -1, 42, 43, 44, -1, -1, 47, -1, -1,
- -1, 51, -1, 53, -1, 55, -1, -1, -1, 59,
- -1, 61, -1, -1, -1, 65, 66, 67, 68, 69,
- 70, 71, 72, 73, 74, 75, 76, 77, 78, -1,
- -1, 81, 82, 83, 84, 85, 86, 87, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, 87, -1, -1, -1, -1, 92, -1, -1, -1,
+ -1, -1, -1, -1, -1, 4, 5, 6, -1, -1,
+ 9, 10, 11, 12, 13, 14, -1, 16, -1, -1,
+ -1, 20, 21, 22, -1, -1, -1, -1, -1, -1,
+ 29, 30, 31, 32, 33, 34, -1, 36, -1, -1,
+ -1, 40, -1, 42, 43, 44, -1, -1, 47, -1,
+ -1, -1, 51, -1, 53, -1, -1, -1, -1, -1,
+ 59, -1, 61, -1, -1, -1, 65, 66, 67, 68,
+ 69, 70, 71, 72, 73, 74, 75, 76, 77, 78,
+ -1, -1, 81, 82, 83, 84, 85, 86, 87, -1,
+ -1, -1, -1, 92, -1, -1, -1, -1, -1, -1,
+ -1, -1, 4, 5, 6, -1, -1, 9, 10, 11,
+ 12, 13, 14, -1, 16, -1, -1, -1, 20, 21,
+ 22, -1, -1, -1, -1, -1, -1, 29, 30, 31,
+ 32, 33, 34, -1, 36, -1, -1, -1, 40, -1,
+ 42, 43, 44, -1, -1, 47, -1, -1, -1, 51,
+ -1, 53, -1, 55, -1, -1, -1, 59, -1, 61,
+ -1, -1, -1, 65, 66, 67, 68, 69, 70, 71,
+ 72, 73, 74, 75, 76, 77, 78, -1, -1, 81,
+ 82, 83, 84, 85, 86, 87, -1, -1, -1, -1,
+ 92, -1, -1, -1, -1, -1, -1, -1, -1,
- 3, 2, 15, 25, 25, 3, 25, 3, 2, 11,
- 2, 15, 3, 13, 67, 3, 15, 104, 15, 2,
- 15, 2, 4, 3, 35, 15, 15, 3, 21, 3,
- 93, 15, 2, 2, 19, 13, 15, 96, 25, 25,
- 15, 3, 15, 15, 15, 100, 3, 3, 15, 2,
- 2, 15, 3, 21, 4, 15, 15, 15, 35, 2,
- 21, 2, 2, 2, 98, 3, 2, 2, 2, 35,
- 35, 4, 35, 2, 21, 3, 3, 3, 15, 2,
- 35, 35, 3, 3, 3, 3, 35, 35, 2, 35,
- 21, 35, -1, 35, -1, -1, 13, 2, 13, 44,
- 2, 46, 3, 3, 36, -1, -1, -1, 3, -1,
- -1, 15, -1, 35, 44, -1, 46, 13, 40, 44,
- 44, 46, 46, -1, 41, 15, 41, -1, 44, 15,
- 46, 44, 44, 46, 44, 44, 44, 44, 44, 49,
- 49, 44, 49, 49, 35, 41, 49, 37, 60, 40,
- 58, 44, 44, 46, 46, 44, 44, 44, 3, 44,
- 49, 46, 50, 50, 31, 44, 44, 68, 35, 44,
- 48, 50, 44, 68, 44, 50, 81, 49, 48, 81,
- 44, 85, 44, 44, 44, 49, 48, 44, 49, 49,
- 44, 44, 49, 44, 44, 49, 46, 44, 44, 52,
- 46, 44, 44, 46, 46, 56, 44, 54, 46, 15,
- 3, 44, 44, 99, 47, 47, 44, 44, 46, 46,
- 44, 44, 46, 68, 15, 13, 49, 44, 44, 44,
- 44, 44, 49, 49, 49, 49, 49, -1, 61, 53,
- 28, 29, 55, -1, -1, -1, 37, 38, 44, 66,
- 66, 66, 44, 49, 44, 51, -1, 49, 44, 49,
- -1, 44, -1, 49, 44, -1, 49, 57, 44, 49,
- 46, 51, 44, -1, 66, 68, 59, 49, 44, 51,
- 66, 87, 5, 49, 13, 51, 13, 16, 5, 16,
- 13, 20, 13, 20, -1, -1, 13, -1, -1, 20,
- 21, 22, 23, 24, -1, 28, 29, -1, 35, -1,
- -1, 28, 29, -1, -1, -1, -1, -1, -1, -1,
+ 13, 15, 25, 3, 15, 15, 3, 25, 3, 15,
+ 2, 15, 2, 25, 3, 11, 19, 15, 67, 13,
+ 3, 104, 15, 4, 15, 3, 2, 15, 2, 15,
+ 3, 15, 3, 35, 21, 3, 15, 36, 3, 19,
+ 25, 2, 2, 25, 21, 15, 15, 98, 15, 15,
+ 2, 4, 15, 15, 2, 93, 3, 21, 2, 2,
+ 35, 3, 2, 35, 15, 3, 21, 3, 2, 15,
+ 15, 2, 2, 2, 15, 3, 35, 35, 35, 35,
+ 3, 35, 3, 3, 21, 35, 35, 96, 15, 3,
+ 2, 4, 3, 2, 2, 100, 35, 3, 3, 2,
+ 35, 2, -1, -1, -1, 15, -1, -1, -1, -1,
+ -1, 44, 44, 46, 46, 13, -1, -1, 44, 44,
+ 44, 46, 46, 15, 15, 44, 44, 44, 54, 44,
+ 49, 49, 49, 3, 49, 15, -1, 44, -1, -1,
+ 44, 48, 44, 41, 48, 44, 37, 46, 44, 44,
+ 35, 44, 35, 46, 49, 40, 58, 40, 44, 3,
+ 44, -1, 48, 68, 60, 49, 44, 44, 44, 44,
+ -1, 49, 49, 49, 49, 85, 44, 44, 81, 46,
+ 81, 44, 44, 46, 52, 44, 44, 46, 50, 44,
+ 31, 46, 50, 13, 35, 87, 44, 2, 68, 47,
+ 20, 44, 44, 46, 46, 44, 13, 44, 47, 46,
+ 44, 44, 46, 44, 44, 46, 49, 13, 44, 99,
+ 46, 44, 44, 46, 68, 44, 56, 44, 50, 46,
+ 49, 44, -1, 44, 41, 44, 15, 50, 49, -1,
+ 49, 13, 44, 13, 44, 41, 16, 49, 57, 49,
+ 20, -1, -1, -1, -1, 66, 28, 29, 37, 38,
+ 44, 61, -1, 44, 66, 49, 44, 51, 49, 44,
+ 51, 49, -1, 51, 49, 44, 44, 44, -1, 44,
+ 49, 49, 49, 13, 49, -1, 16, 55, 53, 44,
+ 20, 66, 59, 44, 49, 5, -1, 66, 49, 13,
+ 51, 3, 16, 13, -1, 13, 20, -1, -1, -1,
+ -1, 66, 20, 21, 22, 23, 24, -1, 28, 29,
+ -1, 35, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 68, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 13, -1, -1, 16, -1, -1, -1, 20, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 5, -1, -1, -1, -1, -1,
+ -1, -1, 13, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 28, 29, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
@@ -934,6 +987,6 @@ const short QDeclarativeJSGrammar::action_check [] = {
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1};
+ -1, -1, -1, -1, -1};
QT_END_NAMESPACE
diff --git a/src/declarative/qml/parser/qdeclarativejsgrammar_p.h b/src/declarative/qml/parser/qdeclarativejsgrammar_p.h
index d6c3d6b..2b2e3d1 100644
--- a/src/declarative/qml/parser/qdeclarativejsgrammar_p.h
+++ b/src/declarative/qml/parser/qdeclarativejsgrammar_p.h
@@ -61,10 +61,10 @@ QT_BEGIN_NAMESPACE
class QDeclarativeJSGrammar
{
public:
- enum VariousConstants {
+ enum {
EOF_SYMBOL = 0,
- REDUCE_HERE = 99,
- SHIFT_THERE = 98,
+ REDUCE_HERE = 100,
+ SHIFT_THERE = 99,
T_AND = 1,
T_AND_AND = 2,
T_AND_EQ = 3,
@@ -90,12 +90,12 @@ public:
T_EQ_EQ = 18,
T_EQ_EQ_EQ = 19,
T_FALSE = 83,
- T_FEED_JS_EXPRESSION = 95,
- T_FEED_JS_PROGRAM = 97,
- T_FEED_JS_SOURCE_ELEMENT = 96,
- T_FEED_JS_STATEMENT = 94,
- T_FEED_UI_OBJECT_MEMBER = 93,
- T_FEED_UI_PROGRAM = 92,
+ T_FEED_JS_EXPRESSION = 96,
+ T_FEED_JS_PROGRAM = 98,
+ T_FEED_JS_SOURCE_ELEMENT = 97,
+ T_FEED_JS_STATEMENT = 95,
+ T_FEED_UI_OBJECT_MEMBER = 94,
+ T_FEED_UI_PROGRAM = 93,
T_FINALLY = 20,
T_FOR = 21,
T_FUNCTION = 22,
@@ -127,6 +127,7 @@ public:
T_NOT_EQ_EQ = 46,
T_NULL = 81,
T_NUMERIC_LITERAL = 47,
+ T_ON = 92,
T_OR = 48,
T_OR_EQ = 49,
T_OR_OR = 50,
@@ -163,15 +164,15 @@ public:
T_XOR = 79,
T_XOR_EQ = 80,
- ACCEPT_STATE = 635,
- RULE_COUNT = 343,
- STATE_COUNT = 636,
- TERMINAL_COUNT = 100,
+ ACCEPT_STATE = 639,
+ RULE_COUNT = 345,
+ STATE_COUNT = 640,
+ TERMINAL_COUNT = 101,
NON_TERMINAL_COUNT = 106,
- GOTO_INDEX_OFFSET = 636,
- GOTO_INFO_OFFSET = 2520,
- GOTO_CHECK_OFFSET = 2520
+ GOTO_INDEX_OFFSET = 640,
+ GOTO_INFO_OFFSET = 2699,
+ GOTO_CHECK_OFFSET = 2699
};
static const char *const spell [];
diff --git a/src/declarative/qml/parser/qdeclarativejslexer.cpp b/src/declarative/qml/parser/qdeclarativejslexer.cpp
index 384d00c..34163a4 100644
--- a/src/declarative/qml/parser/qdeclarativejslexer.cpp
+++ b/src/declarative/qml/parser/qdeclarativejslexer.cpp
@@ -166,6 +166,8 @@ int Lexer::findReservedWord(const QChar *c, int size) const
return QDeclarativeJSGrammar::T_IN;
else if (c[0] == QLatin1Char('a') && c[1] == QLatin1Char('s'))
return QDeclarativeJSGrammar::T_AS;
+ else if (c[0] == QLatin1Char('o') && c[1] == QLatin1Char('n'))
+ return QDeclarativeJSGrammar::T_ON;
} break;
case 3: {
diff --git a/src/declarative/qml/parser/qdeclarativejsparser.cpp b/src/declarative/qml/parser/qdeclarativejsparser.cpp
index 4aa4960..fd9e690 100644
--- a/src/declarative/qml/parser/qdeclarativejsparser.cpp
+++ b/src/declarative/qml/parser/qdeclarativejsparser.cpp
@@ -356,7 +356,15 @@ case 32: {
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 33:case 34:case 35:case 36:
+
+case 33: {
+ AST::UiObjectBinding *node = makeAstNode<AST::UiObjectBinding> (driver->nodePool(),
+ sym(3).UiQualifiedId, sym(1).UiQualifiedId, sym(4).UiObjectInitializer);
+ node->colonToken = loc(2);
+ node->hasOnToken = true;
+ sym(1).Node = node;
+} break;
+case 34:case 35:case 36:case 37:
{
AST::UiScriptBinding *node = makeAstNode<AST::UiScriptBinding> (driver->nodePool(),
sym(1).UiQualifiedId, sym(3).Statement);
@@ -364,35 +372,35 @@ case 33:case 34:case 35:case 36:
sym(1).Node = node;
} break;
-case 37:
+case 38:
-case 38: {
+case 39: {
sym(1).sval = driver->intern(lexer->characterBuffer(), lexer->characterCount());
break;
}
-case 40: {
+case 41: {
sym(1).Node = 0;
} break;
-case 41: {
+case 42: {
sym(1).Node = sym(1).UiParameterList->finish ();
} break;
-case 42: {
+case 43: {
AST::UiParameterList *node = makeAstNode<AST::UiParameterList> (driver->nodePool(), sym(1).sval, sym(2).sval);
node->identifierToken = loc(2);
sym(1).Node = node;
} break;
-case 43: {
+case 44: {
AST::UiParameterList *node = makeAstNode<AST::UiParameterList> (driver->nodePool(), sym(1).UiParameterList, sym(3).sval, sym(4).sval);
node->commaToken = loc(2);
node->identifierToken = loc(4);
sym(1).Node = node;
} break;
-case 45: {
+case 46: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), (NameId *)0, sym(2).sval);
node->type = AST::UiPublicMember::Signal;
node->propertyToken = loc(1);
@@ -403,7 +411,7 @@ case 45: {
sym(1).Node = node;
} break;
-case 47: {
+case 48: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), (NameId *)0, sym(2).sval);
node->type = AST::UiPublicMember::Signal;
node->propertyToken = loc(1);
@@ -413,7 +421,7 @@ case 47: {
sym(1).Node = node;
} break;
-case 49: {
+case 50: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(4).sval, sym(6).sval);
node->typeModifier = sym(2).sval;
node->propertyToken = loc(1);
@@ -424,7 +432,7 @@ case 49: {
sym(1).Node = node;
} break;
-case 51: {
+case 52: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval);
node->propertyToken = loc(1);
node->typeToken = loc(2);
@@ -433,7 +441,7 @@ case 51: {
sym(1).Node = node;
} break;
-case 53: {
+case 54: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval);
node->isDefaultMember = true;
node->defaultToken = loc(1);
@@ -444,7 +452,7 @@ case 53: {
sym(1).Node = node;
} break;
-case 55: {
+case 56: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval,
sym(5).Expression);
node->propertyToken = loc(1);
@@ -455,7 +463,7 @@ case 55: {
sym(1).Node = node;
} break;
-case 57: {
+case 58: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval,
sym(6).Expression);
node->isReadonlyMember = true;
@@ -468,7 +476,7 @@ case 57: {
sym(1).Node = node;
} break;
-case 59: {
+case 60: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval,
sym(6).Expression);
node->isDefaultMember = true;
@@ -481,75 +489,81 @@ case 59: {
sym(1).Node = node;
} break;
-case 60: {
+case 61: {
sym(1).Node = makeAstNode<AST::UiSourceElement>(driver->nodePool(), sym(1).Node);
} break;
-case 61: {
+case 62: {
sym(1).Node = makeAstNode<AST::UiSourceElement>(driver->nodePool(), sym(1).Node);
} break;
-case 63: {
+case 64: {
QString s = QLatin1String(QDeclarativeJSGrammar::spell[T_PROPERTY]);
sym(1).sval = driver->intern(s.constData(), s.length());
break;
}
-case 64: {
+case 65: {
QString s = QLatin1String(QDeclarativeJSGrammar::spell[T_SIGNAL]);
sym(1).sval = driver->intern(s.constData(), s.length());
break;
}
-case 65: {
+case 66: {
QString s = QLatin1String(QDeclarativeJSGrammar::spell[T_READONLY]);
sym(1).sval = driver->intern(s.constData(), s.length());
break;
}
-case 66: {
+case 67: {
+ QString s = QLatin1String(QDeclarativeJSGrammar::spell[T_READONLY]);
+ sym(1).sval = driver->intern(s.constData(), s.length());
+ break;
+}
+
+case 68: {
AST::ThisExpression *node = makeAstNode<AST::ThisExpression> (driver->nodePool());
node->thisToken = loc(1);
sym(1).Node = node;
} break;
-case 67: {
+case 69: {
AST::IdentifierExpression *node = makeAstNode<AST::IdentifierExpression> (driver->nodePool(), sym(1).sval);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 68: {
+case 70: {
AST::NullExpression *node = makeAstNode<AST::NullExpression> (driver->nodePool());
node->nullToken = loc(1);
sym(1).Node = node;
} break;
-case 69: {
+case 71: {
AST::TrueLiteral *node = makeAstNode<AST::TrueLiteral> (driver->nodePool());
node->trueToken = loc(1);
sym(1).Node = node;
} break;
-case 70: {
+case 72: {
AST::FalseLiteral *node = makeAstNode<AST::FalseLiteral> (driver->nodePool());
node->falseToken = loc(1);
sym(1).Node = node;
} break;
-case 71: {
+case 73: {
AST::NumericLiteral *node = makeAstNode<AST::NumericLiteral> (driver->nodePool(), sym(1).dval);
node->literalToken = loc(1);
sym(1).Node = node;
} break;
-case 72:
-case 73: {
+case 74:
+case 75: {
AST::StringLiteral *node = makeAstNode<AST::StringLiteral> (driver->nodePool(), sym(1).sval);
node->literalToken = loc(1);
sym(1).Node = node;
} break;
-case 74: {
+case 76: {
bool rx = lexer->scanRegExp(Lexer::NoPrefix);
if (!rx) {
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, location(lexer), lexer->errorMessage()));
@@ -560,7 +574,7 @@ case 74: {
sym(1).Node = node;
} break;
-case 75: {
+case 77: {
bool rx = lexer->scanRegExp(Lexer::EqualPrefix);
if (!rx) {
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, location(lexer), lexer->errorMessage()));
@@ -571,28 +585,28 @@ case 75: {
sym(1).Node = node;
} break;
-case 76: {
+case 78: {
AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), (AST::Elision *) 0);
node->lbracketToken = loc(1);
node->rbracketToken = loc(2);
sym(1).Node = node;
} break;
-case 77: {
+case 79: {
AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).Elision->finish());
node->lbracketToken = loc(1);
node->rbracketToken = loc(3);
sym(1).Node = node;
} break;
-case 78: {
+case 80: {
AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).ElementList->finish ());
node->lbracketToken = loc(1);
node->rbracketToken = loc(3);
sym(1).Node = node;
} break;
-case 79: {
+case 81: {
AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).ElementList->finish (),
(AST::Elision *) 0);
node->lbracketToken = loc(1);
@@ -601,7 +615,7 @@ case 79: {
sym(1).Node = node;
} break;
-case 80: {
+case 82: {
AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).ElementList->finish (),
sym(4).Elision->finish());
node->lbracketToken = loc(1);
@@ -610,7 +624,7 @@ case 80: {
sym(1).Node = node;
} break;
-case 81: {
+case 83: {
AST::ObjectLiteral *node = 0;
if (sym(2).Node)
node = makeAstNode<AST::ObjectLiteral> (driver->nodePool(),
@@ -622,7 +636,7 @@ case 81: {
sym(1).Node = node;
} break;
-case 82: {
+case 84: {
AST::ObjectLiteral *node = makeAstNode<AST::ObjectLiteral> (driver->nodePool(),
sym(2).PropertyNameAndValueList->finish ());
node->lbraceToken = loc(1);
@@ -630,14 +644,14 @@ case 82: {
sym(1).Node = node;
} break;
-case 83: {
+case 85: {
AST::NestedExpression *node = makeAstNode<AST::NestedExpression>(driver->nodePool(), sym(2).Expression);
node->lparenToken = loc(1);
node->rparenToken = loc(3);
sym(1).Node = node;
} break;
-case 84: {
+case 86: {
if (AST::ArrayMemberExpression *mem = AST::cast<AST::ArrayMemberExpression *>(sym(1).Expression)) {
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Warning, mem->lbracketToken,
QLatin1String("Ignored annotation")));
@@ -657,48 +671,48 @@ case 84: {
}
} break;
-case 85: {
+case 87: {
sym(1).Node = makeAstNode<AST::ElementList> (driver->nodePool(), (AST::Elision *) 0, sym(1).Expression);
} break;
-case 86: {
+case 88: {
sym(1).Node = makeAstNode<AST::ElementList> (driver->nodePool(), sym(1).Elision->finish(), sym(2).Expression);
} break;
-case 87: {
+case 89: {
AST::ElementList *node = makeAstNode<AST::ElementList> (driver->nodePool(), sym(1).ElementList,
(AST::Elision *) 0, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 88: {
+case 90: {
AST::ElementList *node = makeAstNode<AST::ElementList> (driver->nodePool(), sym(1).ElementList, sym(3).Elision->finish(),
sym(4).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 89: {
+case 91: {
AST::Elision *node = makeAstNode<AST::Elision> (driver->nodePool());
node->commaToken = loc(1);
sym(1).Node = node;
} break;
-case 90: {
+case 92: {
AST::Elision *node = makeAstNode<AST::Elision> (driver->nodePool(), sym(1).Elision);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 91: {
+case 93: {
AST::PropertyNameAndValueList *node = makeAstNode<AST::PropertyNameAndValueList> (driver->nodePool(),
sym(1).PropertyName, sym(3).Expression);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 92: {
+case 94: {
AST::PropertyNameAndValueList *node = makeAstNode<AST::PropertyNameAndValueList> (driver->nodePool(),
sym(1).PropertyNameAndValueList, sym(3).PropertyName, sym(5).Expression);
node->commaToken = loc(2);
@@ -706,40 +720,36 @@ case 92: {
sym(1).Node = node;
} break;
-case 93: {
+case 95: {
AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), sym(1).sval);
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 94:
-case 95: {
+case 96:
+case 97: {
AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), driver->intern(lexer->characterBuffer(), lexer->characterCount()));
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 96: {
+case 98: {
AST::StringLiteralPropertyName *node = makeAstNode<AST::StringLiteralPropertyName> (driver->nodePool(), sym(1).sval);
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 97: {
+case 99: {
AST::NumericLiteralPropertyName *node = makeAstNode<AST::NumericLiteralPropertyName> (driver->nodePool(), sym(1).dval);
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 98: {
+case 100: {
AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), sym(1).sval);
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 99:
-
-case 100:
-
case 101:
case 102:
@@ -797,25 +807,29 @@ case 127:
case 128:
case 129:
+
+case 130:
+
+case 131:
{
sym(1).sval = driver->intern(lexer->characterBuffer(), lexer->characterCount());
} break;
-case 134: {
+case 136: {
AST::ArrayMemberExpression *node = makeAstNode<AST::ArrayMemberExpression> (driver->nodePool(), sym(1).Expression, sym(3).Expression);
node->lbracketToken = loc(2);
node->rbracketToken = loc(4);
sym(1).Node = node;
} break;
-case 135: {
+case 137: {
AST::FieldMemberExpression *node = makeAstNode<AST::FieldMemberExpression> (driver->nodePool(), sym(1).Expression, sym(3).sval);
node->dotToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 136: {
+case 138: {
AST::NewMemberExpression *node = makeAstNode<AST::NewMemberExpression> (driver->nodePool(), sym(2).Expression, sym(4).ArgumentList);
node->newToken = loc(1);
node->lparenToken = loc(3);
@@ -823,316 +837,309 @@ case 136: {
sym(1).Node = node;
} break;
-case 138: {
+case 140: {
AST::NewExpression *node = makeAstNode<AST::NewExpression> (driver->nodePool(), sym(2).Expression);
node->newToken = loc(1);
sym(1).Node = node;
} break;
-case 139: {
+case 141: {
AST::CallExpression *node = makeAstNode<AST::CallExpression> (driver->nodePool(), sym(1).Expression, sym(3).ArgumentList);
node->lparenToken = loc(2);
node->rparenToken = loc(4);
sym(1).Node = node;
} break;
-case 140: {
+case 142: {
AST::CallExpression *node = makeAstNode<AST::CallExpression> (driver->nodePool(), sym(1).Expression, sym(3).ArgumentList);
node->lparenToken = loc(2);
node->rparenToken = loc(4);
sym(1).Node = node;
} break;
-case 141: {
+case 143: {
AST::ArrayMemberExpression *node = makeAstNode<AST::ArrayMemberExpression> (driver->nodePool(), sym(1).Expression, sym(3).Expression);
node->lbracketToken = loc(2);
node->rbracketToken = loc(4);
sym(1).Node = node;
} break;
-case 142: {
+case 144: {
AST::FieldMemberExpression *node = makeAstNode<AST::FieldMemberExpression> (driver->nodePool(), sym(1).Expression, sym(3).sval);
node->dotToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 143: {
+case 145: {
sym(1).Node = 0;
} break;
-case 144: {
+case 146: {
sym(1).Node = sym(1).ArgumentList->finish();
} break;
-case 145: {
+case 147: {
sym(1).Node = makeAstNode<AST::ArgumentList> (driver->nodePool(), sym(1).Expression);
} break;
-case 146: {
+case 148: {
AST::ArgumentList *node = makeAstNode<AST::ArgumentList> (driver->nodePool(), sym(1).ArgumentList, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 150: {
+case 152: {
AST::PostIncrementExpression *node = makeAstNode<AST::PostIncrementExpression> (driver->nodePool(), sym(1).Expression);
node->incrementToken = loc(2);
sym(1).Node = node;
} break;
-case 151: {
+case 153: {
AST::PostDecrementExpression *node = makeAstNode<AST::PostDecrementExpression> (driver->nodePool(), sym(1).Expression);
node->decrementToken = loc(2);
sym(1).Node = node;
} break;
-case 153: {
+case 155: {
AST::DeleteExpression *node = makeAstNode<AST::DeleteExpression> (driver->nodePool(), sym(2).Expression);
node->deleteToken = loc(1);
sym(1).Node = node;
} break;
-case 154: {
+case 156: {
AST::VoidExpression *node = makeAstNode<AST::VoidExpression> (driver->nodePool(), sym(2).Expression);
node->voidToken = loc(1);
sym(1).Node = node;
} break;
-case 155: {
+case 157: {
AST::TypeOfExpression *node = makeAstNode<AST::TypeOfExpression> (driver->nodePool(), sym(2).Expression);
node->typeofToken = loc(1);
sym(1).Node = node;
} break;
-case 156: {
+case 158: {
AST::PreIncrementExpression *node = makeAstNode<AST::PreIncrementExpression> (driver->nodePool(), sym(2).Expression);
node->incrementToken = loc(1);
sym(1).Node = node;
} break;
-case 157: {
+case 159: {
AST::PreDecrementExpression *node = makeAstNode<AST::PreDecrementExpression> (driver->nodePool(), sym(2).Expression);
node->decrementToken = loc(1);
sym(1).Node = node;
} break;
-case 158: {
+case 160: {
AST::UnaryPlusExpression *node = makeAstNode<AST::UnaryPlusExpression> (driver->nodePool(), sym(2).Expression);
node->plusToken = loc(1);
sym(1).Node = node;
} break;
-case 159: {
+case 161: {
AST::UnaryMinusExpression *node = makeAstNode<AST::UnaryMinusExpression> (driver->nodePool(), sym(2).Expression);
node->minusToken = loc(1);
sym(1).Node = node;
} break;
-case 160: {
+case 162: {
AST::TildeExpression *node = makeAstNode<AST::TildeExpression> (driver->nodePool(), sym(2).Expression);
node->tildeToken = loc(1);
sym(1).Node = node;
} break;
-case 161: {
+case 163: {
AST::NotExpression *node = makeAstNode<AST::NotExpression> (driver->nodePool(), sym(2).Expression);
node->notToken = loc(1);
sym(1).Node = node;
} break;
-case 163: {
+case 165: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Mul, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 164: {
+case 166: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Div, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 165: {
+case 167: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Mod, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 167: {
+case 169: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Add, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 168: {
+case 170: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Sub, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 170: {
+case 172: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::LShift, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 171: {
+case 173: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::RShift, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 172: {
+case 174: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::URShift, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 174: {
+case 176: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Lt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 175: {
+case 177: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Gt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 176: {
+case 178: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Le, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 177: {
+case 179: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Ge, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 178: {
+case 180: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::InstanceOf, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 179: {
+case 181: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::In, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 181: {
+case 183: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Lt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 182: {
+case 184: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Gt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 183: {
+case 185: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Le, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 184: {
+case 186: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Ge, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 185: {
+case 187: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::InstanceOf, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 187: {
+case 189: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Equal, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 188: {
+case 190: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::NotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 189: {
+case 191: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::StrictEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 190: {
+case 192: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::StrictNotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 192: {
+case 194: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Equal, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 193: {
+case 195: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::NotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 194: {
+case 196: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::StrictEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 195: {
- AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
- QSOperator::StrictNotEqual, sym(3).Expression);
- node->operatorToken = loc(2);
- sym(1).Node = node;
-} break;
-
case 197: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
- QSOperator::BitAnd, sym(3).Expression);
+ QSOperator::StrictNotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
@@ -1146,7 +1153,7 @@ case 199: {
case 201: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
- QSOperator::BitXor, sym(3).Expression);
+ QSOperator::BitAnd, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
@@ -1160,7 +1167,7 @@ case 203: {
case 205: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
- QSOperator::BitOr, sym(3).Expression);
+ QSOperator::BitXor, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
@@ -1174,7 +1181,7 @@ case 207: {
case 209: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
- QSOperator::And, sym(3).Expression);
+ QSOperator::BitOr, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
@@ -1188,7 +1195,7 @@ case 211: {
case 213: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
- QSOperator::Or, sym(3).Expression);
+ QSOperator::And, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
@@ -1201,6 +1208,13 @@ case 215: {
} break;
case 217: {
+ AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
+ QSOperator::Or, sym(3).Expression);
+ node->operatorToken = loc(2);
+ sym(1).Node = node;
+} break;
+
+case 219: {
AST::ConditionalExpression *node = makeAstNode<AST::ConditionalExpression> (driver->nodePool(), sym(1).Expression,
sym(3).Expression, sym(5).Expression);
node->questionToken = loc(2);
@@ -1208,7 +1222,7 @@ case 217: {
sym(1).Node = node;
} break;
-case 219: {
+case 221: {
AST::ConditionalExpression *node = makeAstNode<AST::ConditionalExpression> (driver->nodePool(), sym(1).Expression,
sym(3).Expression, sym(5).Expression);
node->questionToken = loc(2);
@@ -1216,112 +1230,112 @@ case 219: {
sym(1).Node = node;
} break;
-case 221: {
+case 223: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
sym(2).ival, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 223: {
+case 225: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
sym(2).ival, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 224: {
+case 226: {
sym(1).ival = QSOperator::Assign;
} break;
-case 225: {
+case 227: {
sym(1).ival = QSOperator::InplaceMul;
} break;
-case 226: {
+case 228: {
sym(1).ival = QSOperator::InplaceDiv;
} break;
-case 227: {
+case 229: {
sym(1).ival = QSOperator::InplaceMod;
} break;
-case 228: {
+case 230: {
sym(1).ival = QSOperator::InplaceAdd;
} break;
-case 229: {
+case 231: {
sym(1).ival = QSOperator::InplaceSub;
} break;
-case 230: {
+case 232: {
sym(1).ival = QSOperator::InplaceLeftShift;
} break;
-case 231: {
+case 233: {
sym(1).ival = QSOperator::InplaceRightShift;
} break;
-case 232: {
+case 234: {
sym(1).ival = QSOperator::InplaceURightShift;
} break;
-case 233: {
+case 235: {
sym(1).ival = QSOperator::InplaceAnd;
} break;
-case 234: {
+case 236: {
sym(1).ival = QSOperator::InplaceXor;
} break;
-case 235: {
+case 237: {
sym(1).ival = QSOperator::InplaceOr;
} break;
-case 237: {
+case 239: {
AST::Expression *node = makeAstNode<AST::Expression> (driver->nodePool(), sym(1).Expression, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 238: {
+case 240: {
sym(1).Node = 0;
} break;
-case 241: {
+case 243: {
AST::Expression *node = makeAstNode<AST::Expression> (driver->nodePool(), sym(1).Expression, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 242: {
+case 244: {
sym(1).Node = 0;
} break;
-case 259: {
+case 261: {
AST::Block *node = makeAstNode<AST::Block> (driver->nodePool(), sym(2).StatementList);
node->lbraceToken = loc(1);
node->rbraceToken = loc(3);
sym(1).Node = node;
} break;
-case 260: {
+case 262: {
sym(1).Node = makeAstNode<AST::StatementList> (driver->nodePool(), sym(1).Statement);
} break;
-case 261: {
+case 263: {
sym(1).Node = makeAstNode<AST::StatementList> (driver->nodePool(), sym(1).StatementList, sym(2).Statement);
} break;
-case 262: {
+case 264: {
sym(1).Node = 0;
} break;
-case 263: {
+case 265: {
sym(1).Node = sym(1).StatementList->finish ();
} break;
-case 265: {
+case 267: {
AST::VariableStatement *node = makeAstNode<AST::VariableStatement> (driver->nodePool(),
sym(2).VariableDeclarationList->finish (/*readOnly=*/sym(1).ival == T_CONST));
node->declarationKindToken = loc(1);
@@ -1329,76 +1343,76 @@ case 265: {
sym(1).Node = node;
} break;
-case 266: {
+case 268: {
sym(1).ival = T_CONST;
} break;
-case 267: {
+case 269: {
sym(1).ival = T_VAR;
} break;
-case 268: {
+case 270: {
sym(1).Node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclaration);
} break;
-case 269: {
+case 271: {
AST::VariableDeclarationList *node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(),
sym(1).VariableDeclarationList, sym(3).VariableDeclaration);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 270: {
+case 272: {
sym(1).Node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclaration);
} break;
-case 271: {
+case 273: {
sym(1).Node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclarationList, sym(3).VariableDeclaration);
} break;
-case 272: {
+case 274: {
AST::VariableDeclaration *node = makeAstNode<AST::VariableDeclaration> (driver->nodePool(), sym(1).sval, sym(2).Expression);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 273: {
+case 275: {
AST::VariableDeclaration *node = makeAstNode<AST::VariableDeclaration> (driver->nodePool(), sym(1).sval, sym(2).Expression);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 274: {
+case 276: {
// ### TODO: AST for initializer
sym(1) = sym(2);
} break;
-case 275: {
+case 277: {
sym(1).Node = 0;
} break;
-case 277: {
+case 279: {
// ### TODO: AST for initializer
sym(1) = sym(2);
} break;
-case 278: {
+case 280: {
sym(1).Node = 0;
} break;
-case 280: {
+case 282: {
AST::EmptyStatement *node = makeAstNode<AST::EmptyStatement> (driver->nodePool());
node->semicolonToken = loc(1);
sym(1).Node = node;
} break;
-case 282: {
+case 284: {
AST::ExpressionStatement *node = makeAstNode<AST::ExpressionStatement> (driver->nodePool(), sym(1).Expression);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 283: {
+case 285: {
AST::IfStatement *node = makeAstNode<AST::IfStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement, sym(7).Statement);
node->ifToken = loc(1);
node->lparenToken = loc(2);
@@ -1407,7 +1421,7 @@ case 283: {
sym(1).Node = node;
} break;
-case 284: {
+case 286: {
AST::IfStatement *node = makeAstNode<AST::IfStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement);
node->ifToken = loc(1);
node->lparenToken = loc(2);
@@ -1415,7 +1429,7 @@ case 284: {
sym(1).Node = node;
} break;
-case 286: {
+case 288: {
AST::DoWhileStatement *node = makeAstNode<AST::DoWhileStatement> (driver->nodePool(), sym(2).Statement, sym(5).Expression);
node->doToken = loc(1);
node->whileToken = loc(3);
@@ -1425,7 +1439,7 @@ case 286: {
sym(1).Node = node;
} break;
-case 287: {
+case 289: {
AST::WhileStatement *node = makeAstNode<AST::WhileStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement);
node->whileToken = loc(1);
node->lparenToken = loc(2);
@@ -1433,7 +1447,7 @@ case 287: {
sym(1).Node = node;
} break;
-case 288: {
+case 290: {
AST::ForStatement *node = makeAstNode<AST::ForStatement> (driver->nodePool(), sym(3).Expression,
sym(5).Expression, sym(7).Expression, sym(9).Statement);
node->forToken = loc(1);
@@ -1444,7 +1458,7 @@ case 288: {
sym(1).Node = node;
} break;
-case 289: {
+case 291: {
AST::LocalForStatement *node = makeAstNode<AST::LocalForStatement> (driver->nodePool(),
sym(4).VariableDeclarationList->finish (/*readOnly=*/false), sym(6).Expression,
sym(8).Expression, sym(10).Statement);
@@ -1457,7 +1471,7 @@ case 289: {
sym(1).Node = node;
} break;
-case 290: {
+case 292: {
AST:: ForEachStatement *node = makeAstNode<AST::ForEachStatement> (driver->nodePool(), sym(3).Expression,
sym(5).Expression, sym(7).Statement);
node->forToken = loc(1);
@@ -1467,7 +1481,7 @@ case 290: {
sym(1).Node = node;
} break;
-case 291: {
+case 293: {
AST::LocalForEachStatement *node = makeAstNode<AST::LocalForEachStatement> (driver->nodePool(),
sym(4).VariableDeclaration, sym(6).Expression, sym(8).Statement);
node->forToken = loc(1);
@@ -1478,14 +1492,14 @@ case 291: {
sym(1).Node = node;
} break;
-case 293: {
+case 295: {
AST::ContinueStatement *node = makeAstNode<AST::ContinueStatement> (driver->nodePool());
node->continueToken = loc(1);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 295: {
+case 297: {
AST::ContinueStatement *node = makeAstNode<AST::ContinueStatement> (driver->nodePool(), sym(2).sval);
node->continueToken = loc(1);
node->identifierToken = loc(2);
@@ -1493,14 +1507,14 @@ case 295: {
sym(1).Node = node;
} break;
-case 297: {
+case 299: {
AST::BreakStatement *node = makeAstNode<AST::BreakStatement> (driver->nodePool());
node->breakToken = loc(1);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 299: {
+case 301: {
AST::BreakStatement *node = makeAstNode<AST::BreakStatement> (driver->nodePool(), sym(2).sval);
node->breakToken = loc(1);
node->identifierToken = loc(2);
@@ -1508,14 +1522,14 @@ case 299: {
sym(1).Node = node;
} break;
-case 301: {
+case 303: {
AST::ReturnStatement *node = makeAstNode<AST::ReturnStatement> (driver->nodePool(), sym(2).Expression);
node->returnToken = loc(1);
node->semicolonToken = loc(3);
sym(1).Node = node;
} break;
-case 302: {
+case 304: {
AST::WithStatement *node = makeAstNode<AST::WithStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement);
node->withToken = loc(1);
node->lparenToken = loc(2);
@@ -1523,7 +1537,7 @@ case 302: {
sym(1).Node = node;
} break;
-case 303: {
+case 305: {
AST::SwitchStatement *node = makeAstNode<AST::SwitchStatement> (driver->nodePool(), sym(3).Expression, sym(5).CaseBlock);
node->switchToken = loc(1);
node->lparenToken = loc(2);
@@ -1531,90 +1545,90 @@ case 303: {
sym(1).Node = node;
} break;
-case 304: {
+case 306: {
AST::CaseBlock *node = makeAstNode<AST::CaseBlock> (driver->nodePool(), sym(2).CaseClauses);
node->lbraceToken = loc(1);
node->rbraceToken = loc(3);
sym(1).Node = node;
} break;
-case 305: {
+case 307: {
AST::CaseBlock *node = makeAstNode<AST::CaseBlock> (driver->nodePool(), sym(2).CaseClauses, sym(3).DefaultClause, sym(4).CaseClauses);
node->lbraceToken = loc(1);
node->rbraceToken = loc(5);
sym(1).Node = node;
} break;
-case 306: {
+case 308: {
sym(1).Node = makeAstNode<AST::CaseClauses> (driver->nodePool(), sym(1).CaseClause);
} break;
-case 307: {
+case 309: {
sym(1).Node = makeAstNode<AST::CaseClauses> (driver->nodePool(), sym(1).CaseClauses, sym(2).CaseClause);
} break;
-case 308: {
+case 310: {
sym(1).Node = 0;
} break;
-case 309: {
+case 311: {
sym(1).Node = sym(1).CaseClauses->finish ();
} break;
-case 310: {
+case 312: {
AST::CaseClause *node = makeAstNode<AST::CaseClause> (driver->nodePool(), sym(2).Expression, sym(4).StatementList);
node->caseToken = loc(1);
node->colonToken = loc(3);
sym(1).Node = node;
} break;
-case 311: {
+case 313: {
AST::DefaultClause *node = makeAstNode<AST::DefaultClause> (driver->nodePool(), sym(3).StatementList);
node->defaultToken = loc(1);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 312:
-case 313: {
+case 314:
+case 315: {
AST::LabelledStatement *node = makeAstNode<AST::LabelledStatement> (driver->nodePool(), driver->intern(lexer->characterBuffer(), lexer->characterCount()), sym(3).Statement);
node->identifierToken = loc(1);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 314: {
+case 316: {
AST::LabelledStatement *node = makeAstNode<AST::LabelledStatement> (driver->nodePool(), sym(1).sval, sym(3).Statement);
node->identifierToken = loc(1);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 316: {
+case 318: {
AST::ThrowStatement *node = makeAstNode<AST::ThrowStatement> (driver->nodePool(), sym(2).Expression);
node->throwToken = loc(1);
node->semicolonToken = loc(3);
sym(1).Node = node;
} break;
-case 317: {
+case 319: {
AST::TryStatement *node = makeAstNode<AST::TryStatement> (driver->nodePool(), sym(2).Statement, sym(3).Catch);
node->tryToken = loc(1);
sym(1).Node = node;
} break;
-case 318: {
+case 320: {
AST::TryStatement *node = makeAstNode<AST::TryStatement> (driver->nodePool(), sym(2).Statement, sym(3).Finally);
node->tryToken = loc(1);
sym(1).Node = node;
} break;
-case 319: {
+case 321: {
AST::TryStatement *node = makeAstNode<AST::TryStatement> (driver->nodePool(), sym(2).Statement, sym(3).Catch, sym(4).Finally);
node->tryToken = loc(1);
sym(1).Node = node;
} break;
-case 320: {
+case 322: {
AST::Catch *node = makeAstNode<AST::Catch> (driver->nodePool(), sym(3).sval, sym(5).Block);
node->catchToken = loc(1);
node->lparenToken = loc(2);
@@ -1623,20 +1637,20 @@ case 320: {
sym(1).Node = node;
} break;
-case 321: {
+case 323: {
AST::Finally *node = makeAstNode<AST::Finally> (driver->nodePool(), sym(2).Block);
node->finallyToken = loc(1);
sym(1).Node = node;
} break;
-case 323: {
+case 325: {
AST::DebuggerStatement *node = makeAstNode<AST::DebuggerStatement> (driver->nodePool());
node->debuggerToken = loc(1);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 324: {
+case 326: {
AST::FunctionDeclaration *node = makeAstNode<AST::FunctionDeclaration> (driver->nodePool(), sym(2).sval, sym(4).FormalParameterList, sym(7).FunctionBody);
node->functionToken = loc(1);
node->identifierToken = loc(2);
@@ -1647,7 +1661,7 @@ case 324: {
sym(1).Node = node;
} break;
-case 325: {
+case 327: {
AST::FunctionExpression *node = makeAstNode<AST::FunctionExpression> (driver->nodePool(), sym(2).sval, sym(4).FormalParameterList, sym(7).FunctionBody);
node->functionToken = loc(1);
if (sym(2).sval)
@@ -1659,60 +1673,60 @@ case 325: {
sym(1).Node = node;
} break;
-case 326: {
+case 328: {
AST::FormalParameterList *node = makeAstNode<AST::FormalParameterList> (driver->nodePool(), sym(1).sval);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 327: {
+case 329: {
AST::FormalParameterList *node = makeAstNode<AST::FormalParameterList> (driver->nodePool(), sym(1).FormalParameterList, sym(3).sval);
node->commaToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 328: {
+case 330: {
sym(1).Node = 0;
} break;
-case 329: {
+case 331: {
sym(1).Node = sym(1).FormalParameterList->finish ();
} break;
-case 330: {
+case 332: {
sym(1).Node = 0;
} break;
-case 332: {
+case 334: {
sym(1).Node = makeAstNode<AST::FunctionBody> (driver->nodePool(), sym(1).SourceElements->finish ());
} break;
-case 333: {
+case 335: {
sym(1).Node = makeAstNode<AST::Program> (driver->nodePool(), sym(1).SourceElements->finish ());
} break;
-case 334: {
+case 336: {
sym(1).Node = makeAstNode<AST::SourceElements> (driver->nodePool(), sym(1).SourceElement);
} break;
-case 335: {
+case 337: {
sym(1).Node = makeAstNode<AST::SourceElements> (driver->nodePool(), sym(1).SourceElements, sym(2).SourceElement);
} break;
-case 336: {
+case 338: {
sym(1).Node = makeAstNode<AST::StatementSourceElement> (driver->nodePool(), sym(1).Statement);
} break;
-case 337: {
+case 339: {
sym(1).Node = makeAstNode<AST::FunctionSourceElement> (driver->nodePool(), sym(1).FunctionDeclaration);
} break;
-case 338: {
+case 340: {
sym(1).sval = 0;
} break;
-case 340: {
+case 342: {
sym(1).Node = 0;
} break;
diff --git a/src/declarative/qml/parser/qdeclarativejsparser_p.h b/src/declarative/qml/parser/qdeclarativejsparser_p.h
index c7e097a..3864398 100644
--- a/src/declarative/qml/parser/qdeclarativejsparser_p.h
+++ b/src/declarative/qml/parser/qdeclarativejsparser_p.h
@@ -235,9 +235,9 @@ protected:
-#define J_SCRIPT_REGEXPLITERAL_RULE1 74
+#define J_SCRIPT_REGEXPLITERAL_RULE1 76
-#define J_SCRIPT_REGEXPLITERAL_RULE2 75
+#define J_SCRIPT_REGEXPLITERAL_RULE2 77
QT_QML_END_NAMESPACE
diff --git a/src/declarative/qml/qdeclarativebinding.cpp b/src/declarative/qml/qdeclarativebinding.cpp
index 720c562..88ca5cd 100644
--- a/src/declarative/qml/qdeclarativebinding.cpp
+++ b/src/declarative/qml/qdeclarativebinding.cpp
@@ -97,7 +97,7 @@ QDeclarativeBinding::~QDeclarativeBinding()
{
}
-void QDeclarativeBinding::setTarget(const QDeclarativeMetaProperty &prop)
+void QDeclarativeBinding::setTarget(const QDeclarativeProperty &prop)
{
Q_D(QDeclarativeBinding);
d->bindingData()->property = prop;
@@ -105,13 +105,13 @@ void QDeclarativeBinding::setTarget(const QDeclarativeMetaProperty &prop)
update();
}
-QDeclarativeMetaProperty QDeclarativeBinding::property() const
+QDeclarativeProperty QDeclarativeBinding::property() const
{
Q_D(const QDeclarativeBinding);
return d->bindingData()->property;
}
-void QDeclarativeBinding::update(QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeBinding::update(QDeclarativePropertyPrivate::WriteFlags flags)
{
Q_D(QDeclarativeBinding);
@@ -130,7 +130,7 @@ void QDeclarativeBinding::update(QDeclarativeMetaPropertyPrivate::WriteFlags fla
if (data->property.propertyType() == qMetaTypeId<QDeclarativeBinding *>()) {
- int idx = data->property.coreIndex();
+ int idx = data->property.index();
Q_ASSERT(idx != -1);
@@ -161,7 +161,7 @@ void QDeclarativeBinding::update(QDeclarativeMetaPropertyPrivate::WriteFlags fla
data->error.setDescription(QLatin1String("Unable to assign [undefined] to ") + QLatin1String(QMetaType::typeName(data->property.propertyType())));
} else if (!isUndefined && data->property.object() &&
- !QDeclarativeMetaPropertyPrivate::write(data->property, value, flags)) {
+ !QDeclarativePropertyPrivate::write(data->property, value, flags)) {
QUrl url = QUrl(data->url);
int line = data->line;
@@ -204,7 +204,7 @@ void QDeclarativeBindingPrivate::emitValueChanged()
q->update();
}
-void QDeclarativeBinding::setEnabled(bool e, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeBinding::setEnabled(bool e, QDeclarativePropertyPrivate::WriteFlags flags)
{
Q_D(QDeclarativeBinding);
d->bindingData()->enabled = e;
@@ -223,7 +223,7 @@ void QDeclarativeBinding::setEnabled(bool e, QDeclarativeMetaPropertyPrivate::Wr
int QDeclarativeBinding::propertyIndex()
{
Q_D(QDeclarativeBinding);
- return d->bindingData()->property.coreIndex();
+ return d->bindingData()->property.index();
}
bool QDeclarativeBinding::enabled() const
@@ -300,7 +300,7 @@ QString QDeclarativeAbstractBinding::expression() const
return QLatin1String("<Unknown>");
}
-void QDeclarativeAbstractBinding::setEnabled(bool e, QDeclarativeMetaPropertyPrivate::WriteFlags)
+void QDeclarativeAbstractBinding::setEnabled(bool e, QDeclarativePropertyPrivate::WriteFlags)
{
if (e) m_mePtr = 0;
}
diff --git a/src/declarative/qml/qdeclarativebinding_p.h b/src/declarative/qml/qdeclarativebinding_p.h
index ac174fa..f66b9c7 100644
--- a/src/declarative/qml/qdeclarativebinding_p.h
+++ b/src/declarative/qml/qdeclarativebinding_p.h
@@ -56,8 +56,8 @@
#include "qdeclarative.h"
#include "qdeclarativepropertyvaluesource.h"
#include "qdeclarativeexpression.h"
-#include "qdeclarativemetaproperty.h"
-#include "qdeclarativemetaproperty_p.h"
+#include "qdeclarativeproperty.h"
+#include "qdeclarativeproperty_p.h"
#include <QtCore/QObject>
#include <QtCore/QMetaProperty>
@@ -74,12 +74,12 @@ public:
virtual QString expression() const;
- void setEnabled(bool e) { setEnabled(e, QDeclarativeMetaPropertyPrivate::DontRemoveBinding); }
- virtual void setEnabled(bool, QDeclarativeMetaPropertyPrivate::WriteFlags) = 0;
+ void setEnabled(bool e) { setEnabled(e, QDeclarativePropertyPrivate::DontRemoveBinding); }
+ virtual void setEnabled(bool, QDeclarativePropertyPrivate::WriteFlags) = 0;
virtual int propertyIndex() = 0;
- void update() { update(QDeclarativeMetaPropertyPrivate::DontRemoveBinding); }
- virtual void update(QDeclarativeMetaPropertyPrivate::WriteFlags) = 0;
+ void update() { update(QDeclarativePropertyPrivate::DontRemoveBinding); }
+ virtual void update(QDeclarativePropertyPrivate::WriteFlags) = 0;
void addToObject(QObject *);
void removeFromObject();
@@ -89,8 +89,8 @@ protected:
private:
friend class QDeclarativeDeclarativeData;
- friend class QDeclarativeMetaProperty;
- friend class QDeclarativeMetaPropertyPrivate;
+ friend class QDeclarativeProperty;
+ friend class QDeclarativePropertyPrivate;
friend class QDeclarativeVME;
QObject *m_object;
@@ -110,19 +110,19 @@ public:
QObject *parent);
~QDeclarativeBinding();
- void setTarget(const QDeclarativeMetaProperty &);
- QDeclarativeMetaProperty property() const;
+ void setTarget(const QDeclarativeProperty &);
+ QDeclarativeProperty property() const;
bool enabled() const;
// Inherited from QDeclarativeAbstractBinding
- virtual void setEnabled(bool, QDeclarativeMetaPropertyPrivate::WriteFlags flags);
+ virtual void setEnabled(bool, QDeclarativePropertyPrivate::WriteFlags flags);
virtual int propertyIndex();
- virtual void update(QDeclarativeMetaPropertyPrivate::WriteFlags flags);
+ virtual void update(QDeclarativePropertyPrivate::WriteFlags flags);
virtual QString expression() const;
public Q_SLOTS:
- void update() { update(QDeclarativeMetaPropertyPrivate::DontRemoveBinding); }
+ void update() { update(QDeclarativePropertyPrivate::DontRemoveBinding); }
protected:
void emitValueChanged();
diff --git a/src/declarative/qml/qdeclarativebinding_p_p.h b/src/declarative/qml/qdeclarativebinding_p_p.h
index ac88400..041103c 100644
--- a/src/declarative/qml/qdeclarativebinding_p_p.h
+++ b/src/declarative/qml/qdeclarativebinding_p_p.h
@@ -55,7 +55,7 @@
#include "qdeclarativebinding_p.h"
-#include "qdeclarativemetaproperty.h"
+#include "qdeclarativeproperty.h"
#include "qdeclarativeexpression_p.h"
QT_BEGIN_NAMESPACE
@@ -69,7 +69,7 @@ public:
bool updating:1;
bool enabled:1;
- QDeclarativeMetaProperty property;
+ QDeclarativeProperty property;
virtual void refresh();
};
diff --git a/src/declarative/qml/qdeclarativeboundsignal.cpp b/src/declarative/qml/qdeclarativeboundsignal.cpp
index ce396fd..6a5a102 100644
--- a/src/declarative/qml/qdeclarativeboundsignal.cpp
+++ b/src/declarative/qml/qdeclarativeboundsignal.cpp
@@ -104,7 +104,7 @@ QDeclarativeBoundSignal::QDeclarativeBoundSignal(QObject *scope, const QMetaMeth
// is that they both do the work to figure it out. Boo hoo.
if (evaluateIdx == -1) evaluateIdx = metaObject()->methodCount();
- QDeclarativeGraphics_setParent_noEvent(this, parent);
+ QDeclarative_setParent_noEvent(this, parent);
QMetaObject::connect(scope, m_signal.methodIndex(), this, evaluateIdx);
}
@@ -120,7 +120,7 @@ QDeclarativeBoundSignal::QDeclarativeBoundSignal(QDeclarativeContext *ctxt, cons
// is that they both do the work to figure it out. Boo hoo.
if (evaluateIdx == -1) evaluateIdx = metaObject()->methodCount();
- QDeclarativeGraphics_setParent_noEvent(this, parent);
+ QDeclarative_setParent_noEvent(this, parent);
QMetaObject::connect(scope, m_signal.methodIndex(), this, evaluateIdx);
m_expression = new QDeclarativeExpression(ctxt, val, scope);
diff --git a/src/declarative/qml/qdeclarativecompiledbindings.cpp b/src/declarative/qml/qdeclarativecompiledbindings.cpp
index a88f02e..17937fd 100644
--- a/src/declarative/qml/qdeclarativecompiledbindings.cpp
+++ b/src/declarative/qml/qdeclarativecompiledbindings.cpp
@@ -109,9 +109,9 @@ public:
scope(0), target(0), parent(0) {}
// Inherited from QDeclarativeAbstractBinding
- virtual void setEnabled(bool, QDeclarativeMetaPropertyPrivate::WriteFlags flags);
+ virtual void setEnabled(bool, QDeclarativePropertyPrivate::WriteFlags flags);
virtual int propertyIndex();
- virtual void update(QDeclarativeMetaPropertyPrivate::WriteFlags flags);
+ virtual void update(QDeclarativePropertyPrivate::WriteFlags flags);
virtual void destroy();
int index:30;
@@ -244,7 +244,7 @@ QDeclarativeAbstractBinding *QDeclarativeCompiledBindings::configBinding(int ind
return rv;
}
-void QDeclarativeCompiledBindingsPrivate::Binding::setEnabled(bool e, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeCompiledBindingsPrivate::Binding::setEnabled(bool e, QDeclarativePropertyPrivate::WriteFlags flags)
{
if (e) {
addToObject(target);
@@ -267,7 +267,7 @@ int QDeclarativeCompiledBindingsPrivate::Binding::propertyIndex()
return property & 0xFFFF;
}
-void QDeclarativeCompiledBindingsPrivate::Binding::update(QDeclarativeMetaPropertyPrivate::WriteFlags)
+void QDeclarativeCompiledBindingsPrivate::Binding::update(QDeclarativePropertyPrivate::WriteFlags)
{
parent->run(this);
}
@@ -324,7 +324,7 @@ void QDeclarativeCompiledBindingsPrivate::run(Binding *binding)
run(binding->index, cp, binding, binding->scope, target);
vt->write(binding->target, binding->property & 0xFFFF,
- QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ QDeclarativePropertyPrivate::DontRemoveBinding);
} else {
run(binding->index, cp, binding, binding->scope, binding->target);
}
@@ -1701,7 +1701,7 @@ bool QDeclarativeBindingCompilerPrivate::compile(QDeclarativeJS::AST::Node *node
const QMetaObject *from = type.metaObject;
const QMetaObject *to = engine->rawMetaObjectForType(destination->type);
- if (QDeclarativeMetaPropertyPrivate::canConvert(from, to))
+ if (QDeclarativePropertyPrivate::canConvert(from, to))
type.type = destination->type;
}
diff --git a/src/declarative/qml/qdeclarativecompiler.cpp b/src/declarative/qml/qdeclarativecompiler.cpp
index 9ac65f9..5da207d 100644
--- a/src/declarative/qml/qdeclarativecompiler.cpp
+++ b/src/declarative/qml/qdeclarativecompiler.cpp
@@ -58,7 +58,7 @@
#include "parser/qdeclarativejsast_p.h"
#include "qdeclarativevmemetaobject_p.h"
#include "qdeclarativeexpression_p.h"
-#include "qdeclarativemetaproperty_p.h"
+#include "qdeclarativeproperty_p.h"
#include "qdeclarativerewrite_p.h"
#include "qdeclarativescriptstring.h"
#include "qdeclarativeglobal_p.h"
@@ -1314,8 +1314,9 @@ int QDeclarativeCompiler::componentTypeRef()
return output->types.count() - 1;
}
-int QDeclarativeCompiler::findSignalByName(const QMetaObject *mo, const QByteArray &name)
+QMetaMethod QDeclarativeCompiler::findSignalByName(const QMetaObject *mo, const QByteArray &name)
{
+ Q_ASSERT(mo);
int methods = mo->methodCount();
for (int ii = methods - 1; ii >= 0; --ii) {
QMetaMethod method = mo->method(ii);
@@ -1324,7 +1325,7 @@ int QDeclarativeCompiler::findSignalByName(const QMetaObject *mo, const QByteArr
methodName = methodName.left(idx);
if (methodName == name)
- return ii;
+ return method;
}
// If no signal is found, but the signal is of the form "onBlahChanged",
@@ -1332,11 +1333,14 @@ int QDeclarativeCompiler::findSignalByName(const QMetaObject *mo, const QByteArr
if (name.endsWith("Changed")) {
QByteArray propName = name.mid(0, name.length() - 7);
int propIdx = mo->indexOfProperty(propName.constData());
- if (propIdx >= 0)
- return mo->property(propIdx).notifySignalIndex();
+ if (propIdx >= 0) {
+ QMetaProperty prop = mo->property(propIdx);
+ if (prop.hasNotifySignal())
+ return prop.notifySignal();
+ }
}
- return -1;
+ return QMetaMethod();
}
bool QDeclarativeCompiler::buildSignal(QDeclarativeParser::Property *prop, QDeclarativeParser::Object *obj,
@@ -1351,7 +1355,7 @@ bool QDeclarativeCompiler::buildSignal(QDeclarativeParser::Property *prop, QDecl
if(name[0] >= 'A' && name[0] <= 'Z')
name[0] = name[0] - 'A' + 'a';
- int sigIdx = findSignalByName(obj->metaObject(), name);
+ int sigIdx = findSignalByName(obj->metaObject(), name).methodIndex();
if (sigIdx == -1) {
@@ -2036,7 +2040,7 @@ bool QDeclarativeCompiler::buildPropertyObjectAssignment(QDeclarativeParser::Pro
if (propertyMetaObject) {
const QMetaObject *c = v->object->metatype;
while(c) {
- isAssignable |= (QDeclarativeMetaPropertyPrivate::equal(c, propertyMetaObject));
+ isAssignable |= (QDeclarativePropertyPrivate::equal(c, propertyMetaObject));
c = c->superClass();
}
}
@@ -2619,7 +2623,7 @@ int QDeclarativeCompiler::genValueTypeData(QDeclarativeParser::Property *valueTy
QDeclarativeParser::Property *prop)
{
QByteArray data =
- QDeclarativeMetaPropertyPrivate::saveValueType(prop->parent->metaObject(), prop->index,
+ QDeclarativePropertyPrivate::saveValueType(prop->parent->metaObject(), prop->index,
QDeclarativeEnginePrivate::get(engine)->valueTypes[prop->type]->metaObject(),
valueTypeProp->index);
// valueTypeProp->index, valueTypeProp->type);
@@ -2629,7 +2633,7 @@ int QDeclarativeCompiler::genValueTypeData(QDeclarativeParser::Property *valueTy
int QDeclarativeCompiler::genPropertyData(QDeclarativeParser::Property *prop)
{
- return output->indexForByteArray(QDeclarativeMetaPropertyPrivate::saveProperty(prop->parent->metaObject(), prop->index));
+ return output->indexForByteArray(QDeclarativePropertyPrivate::saveProperty(prop->parent->metaObject(), prop->index));
}
bool QDeclarativeCompiler::completeComponentBuild()
@@ -2735,7 +2739,7 @@ bool QDeclarativeCompiler::canCoerce(int to, QDeclarativeParser::Object *from)
const QMetaObject *fromMo = from->metaObject();
while (fromMo) {
- if (QDeclarativeMetaPropertyPrivate::equal(fromMo, toMo))
+ if (QDeclarativePropertyPrivate::equal(fromMo, toMo))
return true;
fromMo = fromMo->superClass();
}
@@ -2754,7 +2758,7 @@ bool QDeclarativeCompiler::canCoerce(int to, int from)
QDeclarativeEnginePrivate::get(engine)->rawMetaObjectForType(from);
while (fromMo) {
- if (QDeclarativeMetaPropertyPrivate::equal(fromMo, toMo))
+ if (QDeclarativePropertyPrivate::equal(fromMo, toMo))
return true;
fromMo = fromMo->superClass();
}
diff --git a/src/declarative/qml/qdeclarativecompiler_p.h b/src/declarative/qml/qdeclarativecompiler_p.h
index 627490d..2ea3366 100644
--- a/src/declarative/qml/qdeclarativecompiler_p.h
+++ b/src/declarative/qml/qdeclarativecompiler_p.h
@@ -159,6 +159,8 @@ public:
static bool isAttachedPropertyName(const QByteArray &);
static bool isSignalPropertyName(const QByteArray &);
+ static QMetaMethod findSignalByName(const QMetaObject *, const QByteArray &name);
+
private:
static void reset(QDeclarativeCompiledData *);
@@ -263,7 +265,6 @@ private:
int componentTypeRef();
- static int findSignalByName(const QMetaObject *, const QByteArray &name);
static QDeclarativeType *toQmlType(QDeclarativeParser::Object *from);
bool canCoerce(int to, QDeclarativeParser::Object *from);
bool canCoerce(int to, int from);
diff --git a/src/declarative/qml/qdeclarativecomponent.cpp b/src/declarative/qml/qdeclarativecomponent.cpp
index aaf36e0..6a2d2d1 100644
--- a/src/declarative/qml/qdeclarativecomponent.cpp
+++ b/src/declarative/qml/qdeclarativecomponent.cpp
@@ -618,7 +618,7 @@ QDeclarativeComponentPrivate::beginCreate(QDeclarativeContext *context, const QB
QObject *rv = begin(ctxt, ep, cc, start, count, &state, bindings);
if (rv) {
- QDeclarativeGraphics_setParent_noEvent(ctxt, rv);
+ QDeclarative_setParent_noEvent(ctxt, rv);
} else {
delete ctxt;
}
@@ -698,8 +698,8 @@ void QDeclarativeComponentPrivate::complete(QDeclarativeEnginePrivate *enginePri
state->bindValues.at(ii);
for (int jj = 0; jj < bv.count; ++jj) {
if(bv.at(jj))
- bv.at(jj)->setEnabled(true, QDeclarativeMetaPropertyPrivate::BypassInterceptor |
- QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ bv.at(jj)->setEnabled(true, QDeclarativePropertyPrivate::BypassInterceptor |
+ QDeclarativePropertyPrivate::DontRemoveBinding);
}
QDeclarativeEnginePrivate::clear(bv);
}
diff --git a/src/declarative/qml/qdeclarativeengine.cpp b/src/declarative/qml/qdeclarativeengine.cpp
index 4435a5b..af75e98 100644
--- a/src/declarative/qml/qdeclarativeengine.cpp
+++ b/src/declarative/qml/qdeclarativeengine.cpp
@@ -49,7 +49,6 @@
#include "qdeclarativecontext.h"
#include "qdeclarativeexpression.h"
#include "qdeclarativecomponent.h"
-#include "qdeclarativemetaproperty_p.h"
#include "qdeclarativebinding_p_p.h"
#include "qdeclarativevme_p.h"
#include "qdeclarativeenginedebug_p.h"
@@ -110,7 +109,7 @@
#define CSIDL_APPDATA 0x001a // <username>\Application Data
#endif
-Q_DECLARE_METATYPE(QDeclarativeMetaProperty)
+Q_DECLARE_METATYPE(QDeclarativeProperty)
QT_BEGIN_NAMESPACE
@@ -337,6 +336,7 @@ void QDeclarativeEnginePrivate::clear(SimpleList<QDeclarativeParserStatus> &pss)
}
Q_GLOBAL_STATIC(QDeclarativeEngineDebugServer, qmlEngineDebugServer);
+Q_GLOBAL_STATIC(QSet<QString>, qmlEnginePluginsWithRegisteredTypes);
void QDeclarativeEnginePrivate::init()
{
@@ -1409,7 +1409,7 @@ public:
qmldirParser.parse();
foreach (const QDeclarativeDirParser::Plugin &plugin, qmldirParser.plugins()) {
- QString resolvedFilePath = QDeclarativeEnginePrivate::get(engine)->resolvePlugin(dir + QDir::separator() + plugin.path,
+ QString resolvedFilePath = QDeclarativeEnginePrivate::get(engine)->resolvePlugin(QDir(dir + QDir::separator() + plugin.path),
plugin.name);
if (!resolvedFilePath.isEmpty())
@@ -1622,10 +1622,32 @@ void QDeclarativeEngine::addImportPath(const QString& path)
*/
bool QDeclarativeEngine::importExtension(const QString &fileName, const QString &uri)
{
- QPluginLoader loader(fileName);
+ QFileInfo fileInfo(fileName);
+ const QString absoluteFilePath = fileInfo.absoluteFilePath();
+ QPluginLoader loader(absoluteFilePath);
if (QDeclarativeExtensionInterface *iface = qobject_cast<QDeclarativeExtensionInterface *>(loader.instance())) {
- iface->initialize(this, uri.toUtf8().constData());
+ const QByteArray bytes = uri.toUtf8();
+ const char *moduleId = bytes.constData();
+
+ // ### this code should probably be protected with a mutex.
+ if (! qmlEnginePluginsWithRegisteredTypes()->contains(absoluteFilePath)) {
+ // types should only be registered once (they're global).
+
+ qmlEnginePluginsWithRegisteredTypes()->insert(absoluteFilePath);
+ iface->registerTypes(moduleId);
+ }
+
+ QDeclarativeEnginePrivate *d = QDeclarativeEnginePrivate::get(this);
+
+ if (! d->initializedPlugins.contains(absoluteFilePath)) {
+ // things on the engine (eg. adding new global objects) have to be done for every engine.
+
+ // protect against double initialization
+ d->initializedPlugins.insert(absoluteFilePath);
+ iface->initializeEngine(this, moduleId);
+ }
+
return true;
}
@@ -1670,7 +1692,6 @@ QString QDeclarativeEnginePrivate::resolvePlugin(const QDir &dir, const QString
const QStringList &suffixes,
const QString &prefix)
{
- qWarning() << baseName;
foreach (const QString &suffix, suffixes) {
QString pluginFileName = prefix;
diff --git a/src/declarative/qml/qdeclarativeengine_p.h b/src/declarative/qml/qdeclarativeengine_p.h
index c4a40c5..0359f98 100644
--- a/src/declarative/qml/qdeclarativeengine_p.h
+++ b/src/declarative/qml/qdeclarativeengine_p.h
@@ -62,7 +62,7 @@
#include "qdeclarativevaluetype_p.h"
#include "qdeclarativecontext.h"
#include "qdeclarativeexpression.h"
-#include "qdeclarativemetaproperty_p.h"
+#include "qdeclarativeproperty_p.h"
#include "qdeclarativepropertycache_p.h"
#include "qdeclarativeobjectscriptclass_p.h"
#include "qdeclarativecontextscriptclass_p.h"
@@ -267,6 +267,7 @@ public:
QStringList environmentImportPath;
+ QSet<QString> initializedPlugins;
QString resolvePlugin(const QDir &dir, const QString &baseName,
const QStringList &suffixes,
diff --git a/src/declarative/qml/qdeclarativeenginedebug.cpp b/src/declarative/qml/qdeclarativeenginedebug.cpp
index 2ae0b54..09882cb 100644
--- a/src/declarative/qml/qdeclarativeenginedebug.cpp
+++ b/src/declarative/qml/qdeclarativeenginedebug.cpp
@@ -44,8 +44,8 @@
#include "qdeclarativeboundsignal_p.h"
#include "qdeclarativeengine.h"
#include "qdeclarativemetatype_p.h"
-#include "qdeclarativemetaproperty.h"
-#include "qdeclarativemetaproperty_p.h"
+#include "qdeclarativeproperty.h"
+#include "qdeclarativeproperty_p.h"
#include "qdeclarativebinding_p.h"
#include "qdeclarativecontext_p.h"
#include "qdeclarativewatcher_p.h"
@@ -110,7 +110,7 @@ QDeclarativeEngineDebugServer::propertyData(QObject *obj, int propIdx)
rv.name = QString::fromUtf8(prop.name());
rv.hasNotifySignal = prop.hasNotifySignal();
QDeclarativeAbstractBinding *binding =
- QDeclarativeMetaPropertyPrivate::binding(QDeclarativeMetaProperty(obj, rv.name));
+ QDeclarativePropertyPrivate::binding(QDeclarativeProperty(obj, rv.name));
if (binding)
rv.binding = binding->expression();
diff --git a/src/declarative/qml/qdeclarativeenginedebug_p.h b/src/declarative/qml/qdeclarativeenginedebug_p.h
index 89da399..a95449b 100644
--- a/src/declarative/qml/qdeclarativeenginedebug_p.h
+++ b/src/declarative/qml/qdeclarativeenginedebug_p.h
@@ -53,7 +53,7 @@
// We mean it.
//
-#include "../debugger/qdeclarativedebugservice_p.h"
+#include <private/qdeclarativedebugservice_p.h>
#include <QtCore/qurl.h>
#include <QtCore/qvariant.h>
diff --git a/src/declarative/qml/qdeclarativeextensioninterface.h b/src/declarative/qml/qdeclarativeextensioninterface.h
index a8ae064..0fabd6d 100644
--- a/src/declarative/qml/qdeclarativeextensioninterface.h
+++ b/src/declarative/qml/qdeclarativeextensioninterface.h
@@ -55,7 +55,8 @@ class QDeclarativeEngine;
struct Q_DECLARATIVE_EXPORT QDeclarativeExtensionInterface
{
virtual ~QDeclarativeExtensionInterface() {}
- virtual void initialize(QDeclarativeEngine *engine, const char *uri) = 0;
+ virtual void registerTypes(const char *uri) = 0;
+ virtual void initializeEngine(QDeclarativeEngine *engine, const char *uri) = 0;
};
Q_DECLARE_INTERFACE(QDeclarativeExtensionInterface, "com.trolltech.Qt.QDeclarativeExtensionInterface/1.0")
diff --git a/src/declarative/qml/qdeclarativeextensionplugin.cpp b/src/declarative/qml/qdeclarativeextensionplugin.cpp
index 6af3a6d..3d44d63 100644
--- a/src/declarative/qml/qdeclarativeextensionplugin.cpp
+++ b/src/declarative/qml/qdeclarativeextensionplugin.cpp
@@ -63,9 +63,9 @@ QT_BEGIN_NAMESPACE
*/
/*!
- \fn void QDeclarativeExtensionPlugin::initialize(QDeclarativeEngine *engine)
+ \fn void QDeclarativeExtensionPlugin::registerTypes(const char *uri)
- Initializes the extension specified in the given \a engine.
+ Registers the QML types in the given \a uri.
*/
/*!
@@ -84,4 +84,16 @@ QDeclarativeExtensionPlugin::~QDeclarativeExtensionPlugin()
{
}
+/*!
+ \fn void QDeclarativeExtensionPlugin::initializeEngine(QDeclarativeEngine *engine, const char *uri)
+
+ Initializes the extension specified in the given \a engine.
+*/
+
+void QDeclarativeExtensionPlugin::initializeEngine(QDeclarativeEngine *engine, const char *uri)
+{
+ Q_UNUSED(engine);
+ Q_UNUSED(uri);
+}
+
QT_END_NAMESPACE
diff --git a/src/declarative/qml/qdeclarativeextensionplugin.h b/src/declarative/qml/qdeclarativeextensionplugin.h
index 79df52b..c2ad798 100644
--- a/src/declarative/qml/qdeclarativeextensionplugin.h
+++ b/src/declarative/qml/qdeclarativeextensionplugin.h
@@ -62,7 +62,8 @@ public:
explicit QDeclarativeExtensionPlugin(QObject *parent = 0);
~QDeclarativeExtensionPlugin();
- virtual void initialize(QDeclarativeEngine *engine, const char *uri) = 0;
+ virtual void registerTypes(const char *uri) = 0;
+ virtual void initializeEngine(QDeclarativeEngine *engine, const char *uri);
};
QT_END_NAMESPACE
diff --git a/src/declarative/qml/qdeclarativeglobal_p.h b/src/declarative/qml/qdeclarativeglobal_p.h
index bbdc91c..1041992 100644
--- a/src/declarative/qml/qdeclarativeglobal_p.h
+++ b/src/declarative/qml/qdeclarativeglobal_p.h
@@ -79,7 +79,7 @@ struct QDeclarativeGraphics_DerivedObject : public QObject
neither \a parent nor the object's previous parent (if it had one) will
receive ChildRemoved or ChildAdded events.
*/
-inline void QDeclarativeGraphics_setParent_noEvent(QObject *object, QObject *parent)
+inline void QDeclarative_setParent_noEvent(QObject *object, QObject *parent)
{
static_cast<QDeclarativeGraphics_DerivedObject *>(object)->setParent_noEvent(parent);
}
diff --git a/src/declarative/qml/qdeclarativelist.cpp b/src/declarative/qml/qdeclarativelist.cpp
index 4c9586c..9691f32 100644
--- a/src/declarative/qml/qdeclarativelist.cpp
+++ b/src/declarative/qml/qdeclarativelist.cpp
@@ -42,7 +42,7 @@
#include "qdeclarativelist.h"
#include "qdeclarativelist_p.h"
#include "qdeclarativeengine_p.h"
-#include "qdeclarativemetaproperty_p.h"
+#include "qdeclarativeproperty_p.h"
QT_BEGIN_NAMESPACE
@@ -85,18 +85,57 @@ void QDeclarativeListReferencePrivate::release()
delete this;
}
+/*!
+\class QDeclarativeListReference
+\brief The QDeclarativeListReference class allows the manipulation of QDeclarativeListProperty properties.
+
+QDeclarativeListReference allows programs to read from, and assign values to a QML list property in a
+simple and type safe way. A QDeclarativeListReference can be created by passing an object and property
+name or through a QDeclarativeProperty instance. These two are equivalant:
+
+\code
+QDeclarativeListReference ref1(object, "children");
+
+QDeclarativeProperty ref2(object, "children");
+QDeclarativeListReference ref2 = qvariant_cast<QDeclarativeListReference>(ref2.read());
+\endcode
+
+Not all QML list properties support all operations. A set of methods, canAppend(), canAt(), canClear() and
+canCount() allow programs to query whether an operation is supported on a given property.
+
+QML list properties are typesafe. Only QObject's that derive from the correct base class can be assigned to
+the list. The listElementType() method can be used to query the QMetaObject of the QObject type supported.
+Attempting to add objects of the incorrect type to a list property will fail.
+
+Like with normal lists, when accessing a list element by index, it is the callers responsibility to ensure
+that it does not request an out of range element using the count() method before calling at().
+*/
+
+/*!
+Constructs an invalid instance.
+*/
QDeclarativeListReference::QDeclarativeListReference()
: d(0)
{
}
-QDeclarativeListReference::QDeclarativeListReference(QObject *o, const char *property, QDeclarativeEngine *engine)
+/*!
+Constructs a QDeclarativeListReference for \a object's \a property. If \a property is not a list
+property, an invalid QDeclarativeListReference is created. If \a object is destroyed after
+the reference is constructed, it will automatically become invalid. That is, it is safe to hold
+QDeclarativeListReference instances even after \a object is deleted.
+
+Passing \a engine is required to access some QML created list properties. If in doubt, and an engine
+is available, pass it.
+*/
+QDeclarativeListReference::QDeclarativeListReference(QObject *object, const char *property, QDeclarativeEngine *engine)
: d(0)
{
- if (!o || !property) return;
+ if (!object || !property) return;
QDeclarativePropertyCache::Data local;
- QDeclarativePropertyCache::Data *data = QDeclarativePropertyCache::property(engine, o, QLatin1String(property), local);
+ QDeclarativePropertyCache::Data *data =
+ QDeclarativePropertyCache::property(engine, object, QLatin1String(property), local);
if (!data || !(data->flags & QDeclarativePropertyCache::Data::IsQList)) return;
@@ -106,20 +145,22 @@ QDeclarativeListReference::QDeclarativeListReference(QObject *o, const char *pro
if (listType == -1) return;
d = new QDeclarativeListReferencePrivate;
- d->object = o;
+ d->object = object;
d->elementType = p?p->rawMetaObjectForType(listType):QDeclarativeMetaType::qmlType(listType)->baseMetaObject();
d->propertyType = data->propType;
void *args[] = { &d->property, 0 };
- QMetaObject::metacall(o, QMetaObject::ReadProperty, data->coreIndex, args);
+ QMetaObject::metacall(object, QMetaObject::ReadProperty, data->coreIndex, args);
}
+/*! \internal */
QDeclarativeListReference::QDeclarativeListReference(const QDeclarativeListReference &o)
: d(o.d)
{
if (d) d->addref();
}
+/*! \internal */
QDeclarativeListReference &QDeclarativeListReference::operator=(const QDeclarativeListReference &o)
{
if (o.d) o.d->addref();
@@ -128,60 +169,108 @@ QDeclarativeListReference &QDeclarativeListReference::operator=(const QDeclarati
return *this;
}
+/*! \internal */
QDeclarativeListReference::~QDeclarativeListReference()
{
if (d) d->release();
}
+/*!
+Returns true if the instance refers to a valid list property, otherwise false.
+*/
bool QDeclarativeListReference::isValid() const
{
return d && d->object;
}
+/*!
+Returns the list property's object. Returns 0 if the reference is invalid.
+*/
QObject *QDeclarativeListReference::object() const
{
if (isValid()) return d->object;
else return 0;
}
+/*!
+Returns the QMetaObject for the elements stored in the list property. Returns 0 if the reference
+is invalid.
+
+The QMetaObject can be used ahead of time to determine whether a given instance can be added
+to a list.
+*/
const QMetaObject *QDeclarativeListReference::listElementType() const
{
if (isValid()) return d->elementType;
else return 0;
}
+/*!
+Returns true if the list property can be appended to, otherwise false. Returns false if the
+reference is invalid.
+
+\sa append()
+*/
bool QDeclarativeListReference::canAppend() const
{
return (isValid() && d->property.append);
}
+/*!
+Returns true if the list property can queried by index, otherwise false. Returns false if the
+reference is invalid.
+
+\sa at()
+*/
bool QDeclarativeListReference::canAt() const
{
return (isValid() && d->property.at);
}
+/*!
+Returns true if the list property can be cleared, otherwise false. Returns false if the
+reference is invalid.
+
+\sa clear()
+*/
bool QDeclarativeListReference::canClear() const
{
return (isValid() && d->property.clear);
}
+/*!
+Returns true if the list property can be queried for its element count, otherwise false.
+Returns false if the reference is invalid.
+
+\sa count()
+*/
bool QDeclarativeListReference::canCount() const
{
return (isValid() && d->property.count);
}
-bool QDeclarativeListReference::append(QObject *o) const
+/*!
+Appends \a object to the list. Returns true if the operation succeeded, otherwise false.
+
+\sa canAppend()
+*/
+bool QDeclarativeListReference::append(QObject *object) const
{
if (!canAppend()) return false;
- if (o && !QDeclarativeMetaPropertyPrivate::canConvert(o->metaObject(), d->elementType))
+ if (object && !QDeclarativePropertyPrivate::canConvert(object->metaObject(), d->elementType))
return false;
- d->property.append(&d->property, o);
+ d->property.append(&d->property, object);
return true;
}
+/*!
+Returns the list element at \a index, or 0 if the operation failed.
+
+\sa canAt()
+*/
QObject *QDeclarativeListReference::at(int index) const
{
if (!canAt()) return 0;
@@ -189,6 +278,11 @@ QObject *QDeclarativeListReference::at(int index) const
return d->property.at(&d->property, index);
}
+/*!
+Clears the list. Returns true if the operation succeeded, otherwise false.
+
+\sa canClear()
+*/
bool QDeclarativeListReference::clear() const
{
if (!canClear()) return false;
@@ -198,6 +292,9 @@ bool QDeclarativeListReference::clear() const
return true;
}
+/*!
+Returns the number of objects in the list, or 0 if the operation failed.
+*/
int QDeclarativeListReference::count() const
{
if (!canCount()) return 0;
diff --git a/src/declarative/qml/qdeclarativemetatype.cpp b/src/declarative/qml/qdeclarativemetatype.cpp
index e87f8ba..abbb9d6 100644
--- a/src/declarative/qml/qdeclarativemetatype.cpp
+++ b/src/declarative/qml/qdeclarativemetatype.cpp
@@ -619,7 +619,7 @@ QDeclarativeType *QDeclarativeMetaType::qmlType(const QByteArray &name, int vers
QList<QDeclarativeType*> types = data->nameToType.values(name);
foreach (QDeclarativeType *t, types) {
- // XXX version_major<0 just a kludge for QDeclarativeMetaPropertyPrivate::initProperty
+ // XXX version_major<0 just a kludge for QDeclarativePropertyPrivate::initProperty
if (version_major<0 || t->availableInVersion(version_major,version_minor))
return t;
}
diff --git a/src/declarative/qml/qdeclarativeobjectscriptclass.cpp b/src/declarative/qml/qdeclarativeobjectscriptclass.cpp
index 50fe5c0..542f417 100644
--- a/src/declarative/qml/qdeclarativeobjectscriptclass.cpp
+++ b/src/declarative/qml/qdeclarativeobjectscriptclass.cpp
@@ -338,7 +338,7 @@ void QDeclarativeObjectScriptClass::setProperty(QObject *obj,
}
}
- QDeclarativeAbstractBinding *delBinding = QDeclarativeMetaPropertyPrivate::setBinding(obj, *lastData, 0);
+ QDeclarativeAbstractBinding *delBinding = QDeclarativePropertyPrivate::setBinding(obj, *lastData, 0);
if (delBinding)
delBinding->destroy();
@@ -348,7 +348,7 @@ void QDeclarativeObjectScriptClass::setProperty(QObject *obj,
} else {
// ### Can well known types be optimized?
QVariant v = QDeclarativeScriptClass::toVariant(engine, value);
- QDeclarativeMetaPropertyPrivate::write(obj, *lastData, v, evalContext);
+ QDeclarativePropertyPrivate::write(obj, *lastData, v, evalContext);
}
}
diff --git a/src/declarative/qml/qdeclarativemetaproperty.cpp b/src/declarative/qml/qdeclarativeproperty.cpp
index a976140..e1ec2cd 100644
--- a/src/declarative/qml/qdeclarativemetaproperty.cpp
+++ b/src/declarative/qml/qdeclarativeproperty.cpp
@@ -39,8 +39,8 @@
**
****************************************************************************/
-#include "qdeclarativemetaproperty.h"
-#include "qdeclarativemetaproperty_p.h"
+#include "qdeclarativeproperty.h"
+#include "qdeclarativeproperty_p.h"
#include "qdeclarativecompositetypedata_p.h"
#include "qdeclarative.h"
@@ -53,6 +53,7 @@
#include "qdeclarativedeclarativedata_p.h"
#include "qdeclarativestringconverters_p.h"
#include "qdeclarativelist_p.h"
+#include "qdeclarativecompiler_p.h"
#include <QStringList>
#include <QtCore/qdebug.h>
@@ -62,71 +63,102 @@
QT_BEGIN_NAMESPACE
/*!
- \class QDeclarativeMetaProperty
- \brief The QDeclarativeMetaProperty class abstracts accessing QML properties.
- \internal
- */
+\class QDeclarativeProperty
+\brief The QDeclarativeProperty class abstracts accessing properties on objects created from QML.
+
+As QML uses Qt's meta-type system all of the existing QMetaObject classes can be used to introspect
+and interact with objects created by QML. However, some of the new features provided by QML - such
+as type safety and attached properties - are most easily used through the QDeclarativeProperty class
+that simplifies some of their natural complexity.
+
+Unlike QMetaProperty which represents a property on a class type, QDeclarativeProperty encapsulates
+a property on a specific object instance. To read a property's value, programmers create a
+QDeclarativeProperty instance and call the read() method. Likewise to write a property value the
+write() method is used.
+
+\code
+
+QObject *object = declarativeComponent.create();
+
+QDeclarativeProperty property(object, "font.pixelSize");
+qWarning() << "Current pixel size:" << property.read().toInt();
+property.write(24);
+qWarning() << "Pixel size should now be 24:" << property.read().toInt();
+
+\endcode
+*/
/*!
- Create an invalid QDeclarativeMetaProperty.
+ Create an invalid QDeclarativeProperty.
*/
-QDeclarativeMetaProperty::QDeclarativeMetaProperty()
-: d(new QDeclarativeMetaPropertyPrivate)
+QDeclarativeProperty::QDeclarativeProperty()
+: d(new QDeclarativePropertyPrivate)
{
d->q = this;
}
/*! \internal */
-QDeclarativeMetaProperty::~QDeclarativeMetaProperty()
+QDeclarativeProperty::~QDeclarativeProperty()
{
delete d; d = 0;
}
/*!
- Creates a QDeclarativeMetaProperty for the default property of \a obj. If there is no
- default property, an invalid QDeclarativeMetaProperty will be created.
+ Creates a QDeclarativeProperty for the default property of \a obj. If there is no
+ default property, an invalid QDeclarativeProperty will be created.
*/
-QDeclarativeMetaProperty::QDeclarativeMetaProperty(QObject *obj)
-: d(new QDeclarativeMetaPropertyPrivate)
+QDeclarativeProperty::QDeclarativeProperty(QObject *obj)
+: d(new QDeclarativePropertyPrivate)
{
d->q = this;
d->initDefault(obj);
}
/*!
- \internal
- Creates a QDeclarativeMetaProperty for the default property of \a obj. If there is no
- default property, an invalid QDeclarativeMetaProperty will be created.
+ Creates a QDeclarativeProperty for the default property of \a obj. If there is no
+ default property, an invalid QDeclarativeProperty will be created.
*/
-QDeclarativeMetaProperty::QDeclarativeMetaProperty(QObject *obj, QDeclarativeContext *ctxt)
-: d(new QDeclarativeMetaPropertyPrivate)
+QDeclarativeProperty::QDeclarativeProperty(QObject *obj, QDeclarativeContext *ctxt)
+: d(new QDeclarativePropertyPrivate)
{
d->q = this;
d->context = ctxt;
+ d->engine = ctxt?ctxt->engine():0;
+ d->initDefault(obj);
+}
+
+/*!
+ Creates a QDeclarativeProperty for the default property of \a obj. If there is no
+ default property, an invalid QDeclarativeProperty will be created.
+ */
+QDeclarativeProperty::QDeclarativeProperty(QObject *obj, QDeclarativeEngine *engine)
+: d(new QDeclarativePropertyPrivate)
+{
+ d->q = this;
+ d->context = 0;
+ d->engine = engine;
d->initDefault(obj);
}
/*!
Initialize from the default property of \a obj
*/
-void QDeclarativeMetaPropertyPrivate::initDefault(QObject *obj)
+void QDeclarativePropertyPrivate::initDefault(QObject *obj)
{
if (!obj)
return;
QMetaProperty p = QDeclarativeMetaType::defaultProperty(obj);
core.load(p);
- if (core.isValid()) {
- isDefaultProperty = true;
+ if (core.isValid())
object = obj;
- }
}
/*!
- Creates a QDeclarativeMetaProperty for the property \a name of \a obj.
+ Creates a QDeclarativeProperty for the property \a name of \a obj.
*/
-QDeclarativeMetaProperty::QDeclarativeMetaProperty(QObject *obj, const QString &name)
-: d(new QDeclarativeMetaPropertyPrivate)
+QDeclarativeProperty::QDeclarativeProperty(QObject *obj, const QString &name)
+: d(new QDeclarativePropertyPrivate)
{
d->q = this;
d->initProperty(obj, name);
@@ -134,25 +166,37 @@ QDeclarativeMetaProperty::QDeclarativeMetaProperty(QObject *obj, const QString &
}
/*!
- \internal
- Creates a QDeclarativeMetaProperty for the property \a name of \a obj.
+ Creates a QDeclarativeProperty for the property \a name of \a obj.
*/
-QDeclarativeMetaProperty::QDeclarativeMetaProperty(QObject *obj, const QString &name, QDeclarativeContext *ctxt)
-: d(new QDeclarativeMetaPropertyPrivate)
+QDeclarativeProperty::QDeclarativeProperty(QObject *obj, const QString &name, QDeclarativeContext *ctxt)
+: d(new QDeclarativePropertyPrivate)
{
d->q = this;
d->context = ctxt;
+ d->engine = ctxt?ctxt->engine():0;
+ d->initProperty(obj, name);
+ if (!isValid()) { d->object = 0; d->context = 0; d->engine = 0; }
+}
+
+/*!
+ Creates a QDeclarativeProperty for the property \a name of \a obj.
+ */
+QDeclarativeProperty::QDeclarativeProperty(QObject *obj, const QString &name, QDeclarativeEngine *engine)
+: d(new QDeclarativePropertyPrivate)
+{
+ d->q = this;
+ d->context = 0;
+ d->engine = engine;
d->initProperty(obj, name);
- if (!isValid()) { d->object = 0; d->context = 0; }
+ if (!isValid()) { d->object = 0; d->context = 0; d->engine = 0; }
}
Q_GLOBAL_STATIC(QDeclarativeValueTypeFactory, qmlValueTypes);
-void QDeclarativeMetaPropertyPrivate::initProperty(QObject *obj, const QString &name)
+void QDeclarativePropertyPrivate::initProperty(QObject *obj, const QString &name)
{
if (!obj) return;
- QDeclarativeEngine *engine = context?context->engine():0;
QDeclarativeTypeNameCache *typeNameCache = context?QDeclarativeContextPrivate::get(context)->imports:0;
QStringList path = name.split(QLatin1Char('.'));
@@ -235,7 +279,7 @@ void QDeclarativeMetaPropertyPrivate::initProperty(QObject *obj, const QString &
QString signalName = terminal.mid(2);
signalName[0] = signalName.at(0).toLower();
- QMetaMethod method = findSignal(currentObject, signalName);
+ QMetaMethod method = QDeclarativeCompiler::findSignalByName(currentObject->metaObject(), signalName.toLatin1().constData());
if (method.signature()) {
object = currentObject;
core.load(method);
@@ -246,7 +290,7 @@ void QDeclarativeMetaPropertyPrivate::initProperty(QObject *obj, const QString &
// Property
QDeclarativePropertyCache::Data local;
QDeclarativePropertyCache::Data *property =
- QDeclarativePropertyCache::property(context?context->engine():0, currentObject, terminal, local);
+ QDeclarativePropertyCache::property(engine, currentObject, terminal, local);
if (property && !(property->flags & QDeclarativePropertyCache::Data::IsFunction)) {
object = currentObject;
core = *property;
@@ -256,63 +300,62 @@ void QDeclarativeMetaPropertyPrivate::initProperty(QObject *obj, const QString &
/*!
Create a copy of \a other.
*/
-QDeclarativeMetaProperty::QDeclarativeMetaProperty(const QDeclarativeMetaProperty &other)
-: d(new QDeclarativeMetaPropertyPrivate(*other.d))
+QDeclarativeProperty::QDeclarativeProperty(const QDeclarativeProperty &other)
+: d(new QDeclarativePropertyPrivate(*other.d))
{
d->q = this;
}
/*!
- \enum QDeclarativeMetaProperty::PropertyTypeCategory
+ \enum QDeclarativeProperty::PropertyTypeCategory
This enum specifies a category of QML property.
- \value InvalidCategory The property is invalid.
- \value List The property is a QList pointer
+ \value InvalidCategory The property is invalid, or is a signal property.
+ \value List The property is a QDeclarativeListProperty list property
\value Object The property is a QObject derived type pointer
- \value Normal The property is none of the above.
+ \value Normal The property is a normal value property.
*/
/*!
- \enum QDeclarativeMetaProperty::Type
+ \enum QDeclarativeProperty::Type
This enum specifies a type of QML property.
\value Invalid The property is invalid.
\value Property The property is a regular Qt property.
\value SignalProperty The property is a signal property.
- \value Default The property is the default property.
*/
/*!
Returns the property category.
*/
-QDeclarativeMetaProperty::PropertyTypeCategory QDeclarativeMetaProperty::propertyTypeCategory() const
+QDeclarativeProperty::PropertyTypeCategory QDeclarativeProperty::propertyTypeCategory() const
{
return d->propertyTypeCategory();
}
-QDeclarativeMetaProperty::PropertyTypeCategory
-QDeclarativeMetaPropertyPrivate::propertyTypeCategory() const
+QDeclarativeProperty::PropertyTypeCategory
+QDeclarativePropertyPrivate::propertyTypeCategory() const
{
uint type = q->type();
- if (type & QDeclarativeMetaProperty::ValueTypeProperty) {
- return QDeclarativeMetaProperty::Normal;
- } else if (type & QDeclarativeMetaProperty::Property) {
+ if (isValueType()) {
+ return QDeclarativeProperty::Normal;
+ } else if (type & QDeclarativeProperty::Property) {
int type = propertyType();
if (type == QVariant::Invalid)
- return QDeclarativeMetaProperty::InvalidCategory;
+ return QDeclarativeProperty::InvalidCategory;
else if ((uint)type < QVariant::UserType)
- return QDeclarativeMetaProperty::Normal;
+ return QDeclarativeProperty::Normal;
else if (core.flags & QDeclarativePropertyCache::Data::IsQObjectDerived)
- return QDeclarativeMetaProperty::Object;
+ return QDeclarativeProperty::Object;
else if (core.flags & QDeclarativePropertyCache::Data::IsQList)
- return QDeclarativeMetaProperty::List;
+ return QDeclarativeProperty::List;
else
- return QDeclarativeMetaProperty::Normal;
+ return QDeclarativeProperty::Normal;
} else {
- return QDeclarativeMetaProperty::InvalidCategory;
+ return QDeclarativeProperty::InvalidCategory;
}
}
@@ -320,9 +363,9 @@ QDeclarativeMetaPropertyPrivate::propertyTypeCategory() const
Returns the type name of the property, or 0 if the property has no type
name.
*/
-const char *QDeclarativeMetaProperty::propertyTypeName() const
+const char *QDeclarativeProperty::propertyTypeName() const
{
- if (type() & ValueTypeProperty) {
+ if (d->isValueType()) {
QDeclarativeEnginePrivate *ep = QDeclarativeEnginePrivate::get(d->context);
QDeclarativeValueType *valueType = 0;
@@ -343,10 +386,10 @@ const char *QDeclarativeMetaProperty::propertyTypeName() const
}
/*!
- Returns true if \a other and this QDeclarativeMetaProperty represent the same
+ Returns true if \a other and this QDeclarativeProperty represent the same
property.
*/
-bool QDeclarativeMetaProperty::operator==(const QDeclarativeMetaProperty &other) const
+bool QDeclarativeProperty::operator==(const QDeclarativeProperty &other) const
{
// category is intentially omitted here as it is generated
// from the other members
@@ -359,17 +402,22 @@ bool QDeclarativeMetaProperty::operator==(const QDeclarativeMetaProperty &other)
Returns the QVariant type of the property, or QVariant::Invalid if the
property has no QVariant type.
*/
-int QDeclarativeMetaProperty::propertyType() const
+int QDeclarativeProperty::propertyType() const
{
return d->propertyType();
}
-int QDeclarativeMetaPropertyPrivate::propertyType() const
+bool QDeclarativePropertyPrivate::isValueType() const
+{
+ return valueType.valueTypeCoreIdx != -1;
+}
+
+int QDeclarativePropertyPrivate::propertyType() const
{
uint type = q->type();
- if (type & QDeclarativeMetaProperty::ValueTypeProperty) {
+ if (isValueType()) {
return valueType.valueTypePropType;
- } else if (type & QDeclarativeMetaProperty::Property) {
+ } else if (type & QDeclarativeProperty::Property) {
if (core.propType == (int)QVariant::LastType)
return qMetaTypeId<QVariant>();
else
@@ -382,51 +430,49 @@ int QDeclarativeMetaPropertyPrivate::propertyType() const
/*!
Returns the type of the property.
*/
-QDeclarativeMetaProperty::Type QDeclarativeMetaProperty::type() const
+QDeclarativeProperty::Type QDeclarativeProperty::type() const
{
if (d->core.flags & QDeclarativePropertyCache::Data::IsFunction)
return SignalProperty;
- else if (d->valueType.valueTypeCoreIdx != -1)
- return (Type)(Property | ValueTypeProperty);
else if (d->core.isValid())
- return (Type)(Property | ((d->isDefaultProperty)?Default:0));
+ return Property;
else
return Invalid;
}
/*!
- Returns true if this QDeclarativeMetaProperty represents a regular Qt property.
+ Returns true if this QDeclarativeProperty represents a regular Qt property.
*/
-bool QDeclarativeMetaProperty::isProperty() const
+bool QDeclarativeProperty::isProperty() const
{
return type() & Property;
}
/*!
- Returns true if this QDeclarativeMetaProperty represents a default property.
+ Returns true if this QDeclarativeProperty represents a QML signal property.
*/
-bool QDeclarativeMetaProperty::isDefault() const
+bool QDeclarativeProperty::isSignalProperty() const
{
- return type() & Default;
+ return type() & SignalProperty;
}
/*!
- Returns the QDeclarativeMetaProperty's QObject.
+ Returns the QDeclarativeProperty's QObject.
*/
-QObject *QDeclarativeMetaProperty::object() const
+QObject *QDeclarativeProperty::object() const
{
return d->object;
}
/*!
- Assign \a other to this QDeclarativeMetaProperty.
+ Assign \a other to this QDeclarativeProperty.
*/
-QDeclarativeMetaProperty &QDeclarativeMetaProperty::operator=(const QDeclarativeMetaProperty &other)
+QDeclarativeProperty &QDeclarativeProperty::operator=(const QDeclarativeProperty &other)
{
d->context = other.d->context;
+ d->engine = other.d->engine;
d->object = other.d->object;
- d->isDefaultProperty = other.d->isDefaultProperty;
d->isNameCached = other.d->isNameCached;
d->core = other.d->core;
d->nameCache = other.d->nameCache;
@@ -439,9 +485,9 @@ QDeclarativeMetaProperty &QDeclarativeMetaProperty::operator=(const QDeclarative
/*!
Returns true if the property is writable, otherwise false.
*/
-bool QDeclarativeMetaProperty::isWritable() const
+bool QDeclarativeProperty::isWritable() const
{
- QDeclarativeMetaProperty::PropertyTypeCategory category = propertyTypeCategory();
+ QDeclarativeProperty::PropertyTypeCategory category = propertyTypeCategory();
if (!d->object)
return false;
@@ -458,7 +504,7 @@ bool QDeclarativeMetaProperty::isWritable() const
/*!
Returns true if the property is designable, otherwise false.
*/
-bool QDeclarativeMetaProperty::isDesignable() const
+bool QDeclarativeProperty::isDesignable() const
{
if (type() & Property && d->core.isValid() && d->object)
return d->object->metaObject()->property(d->core.coreIndex).isDesignable();
@@ -469,7 +515,7 @@ bool QDeclarativeMetaProperty::isDesignable() const
/*!
Returns true if the property is resettable, otherwise false.
*/
-bool QDeclarativeMetaProperty::isResettable() const
+bool QDeclarativeProperty::isResettable() const
{
if (type() & Property && d->core.isValid() && d->object)
return d->core.flags & QDeclarativePropertyCache::Data::IsResettable;
@@ -478,10 +524,10 @@ bool QDeclarativeMetaProperty::isResettable() const
}
/*!
- Returns true if the QDeclarativeMetaProperty refers to a valid property, otherwise
+ Returns true if the QDeclarativeProperty refers to a valid property, otherwise
false.
*/
-bool QDeclarativeMetaProperty::isValid() const
+bool QDeclarativeProperty::isValid() const
{
return type() != Invalid;
}
@@ -489,15 +535,15 @@ bool QDeclarativeMetaProperty::isValid() const
/*!
Return the name of this QML property.
*/
-QString QDeclarativeMetaProperty::name() const
+QString QDeclarativeProperty::name() const
{
if (!d->isNameCached) {
// ###
if (!d->object) {
- } else if (type() & ValueTypeProperty) {
+ } else if (d->isValueType()) {
QString rv = d->core.name(d->object) + QLatin1Char('.');
- QDeclarativeEnginePrivate *ep = d->context?QDeclarativeEnginePrivate::get(d->context->engine()):0;
+ QDeclarativeEnginePrivate *ep = d->engine?QDeclarativeEnginePrivate::get(d->engine):0;
QDeclarativeValueType *valueType = 0;
if (ep) valueType = ep->valueTypes[d->core.propType];
else valueType = QDeclarativeValueTypeFactory::valueType(d->core.propType);
@@ -525,7 +571,7 @@ QString QDeclarativeMetaProperty::name() const
Returns the \l{QMetaProperty} {Qt property} associated with
this QML property.
*/
-QMetaProperty QDeclarativeMetaProperty::property() const
+QMetaProperty QDeclarativeProperty::property() const
{
if (type() & Property && d->core.isValid() && d->object)
return d->object->metaObject()->property(d->core.coreIndex);
@@ -537,7 +583,7 @@ QMetaProperty QDeclarativeMetaProperty::property() const
Return the QMetaMethod for this property if it is a SignalProperty,
otherwise returns an invalid QMetaMethod.
*/
-QMetaMethod QDeclarativeMetaProperty::method() const
+QMetaMethod QDeclarativeProperty::method() const
{
if (type() & SignalProperty && d->object)
return d->object->metaObject()->method(d->core.coreIndex);
@@ -551,7 +597,7 @@ QMetaMethod QDeclarativeMetaProperty::method() const
exists.
*/
QDeclarativeAbstractBinding *
-QDeclarativeMetaPropertyPrivate::binding(const QDeclarativeMetaProperty &that)
+QDeclarativePropertyPrivate::binding(const QDeclarativeProperty &that)
{
if (!that.isProperty() || !that.d->object)
return 0;
@@ -587,7 +633,7 @@ QDeclarativeMetaPropertyPrivate::binding(const QDeclarativeMetaProperty &that)
the binding sets the intial value, it will use these flags for the write).
*/
QDeclarativeAbstractBinding *
-QDeclarativeMetaPropertyPrivate::setBinding(const QDeclarativeMetaProperty &that,
+QDeclarativePropertyPrivate::setBinding(const QDeclarativeProperty &that,
QDeclarativeAbstractBinding *newBinding,
WriteFlags flags)
{
@@ -601,7 +647,7 @@ QDeclarativeMetaPropertyPrivate::setBinding(const QDeclarativeMetaProperty &that
}
QDeclarativeAbstractBinding *
-QDeclarativeMetaPropertyPrivate::setBinding(QObject *object, const QDeclarativePropertyCache::Data &core,
+QDeclarativePropertyPrivate::setBinding(QObject *object, const QDeclarativePropertyCache::Data &core,
QDeclarativeAbstractBinding *newBinding, WriteFlags flags)
{
QDeclarativeDeclarativeData *data = QDeclarativeDeclarativeData::get(object, 0 != newBinding);
@@ -634,9 +680,9 @@ QDeclarativeMetaPropertyPrivate::setBinding(QObject *object, const QDeclarativeP
signal expression exists.
*/
QDeclarativeExpression *
-QDeclarativeMetaPropertyPrivate::signalExpression(const QDeclarativeMetaProperty &that)
+QDeclarativePropertyPrivate::signalExpression(const QDeclarativeProperty &that)
{
- if (!(that.type() & QDeclarativeMetaProperty::SignalProperty))
+ if (!(that.type() & QDeclarativeProperty::SignalProperty))
return 0;
const QObjectList &children = that.d->object->children();
@@ -645,7 +691,7 @@ QDeclarativeMetaPropertyPrivate::signalExpression(const QDeclarativeMetaProperty
QObject *child = children.at(ii);
QDeclarativeBoundSignal *signal = QDeclarativeBoundSignal::cast(child);
- if (signal && signal->index() == that.coreIndex())
+ if (signal && signal->index() == that.index())
return signal->expression();
}
@@ -660,10 +706,10 @@ QDeclarativeMetaPropertyPrivate::signalExpression(const QDeclarativeMetaProperty
assumed by the caller.
*/
QDeclarativeExpression *
-QDeclarativeMetaPropertyPrivate::setSignalExpression(const QDeclarativeMetaProperty &that,
+QDeclarativePropertyPrivate::setSignalExpression(const QDeclarativeProperty &that,
QDeclarativeExpression *expr)
{
- if (!(that.type() & QDeclarativeMetaProperty::SignalProperty)) {
+ if (!(that.type() & QDeclarativeProperty::SignalProperty)) {
delete expr;
return 0;
}
@@ -674,7 +720,7 @@ QDeclarativeMetaPropertyPrivate::setSignalExpression(const QDeclarativeMetaPrope
QObject *child = children.at(ii);
QDeclarativeBoundSignal *signal = QDeclarativeBoundSignal::cast(child);
- if (signal && signal->index() == that.coreIndex())
+ if (signal && signal->index() == that.index())
return signal->setExpression(expr);
}
@@ -686,27 +732,10 @@ QDeclarativeMetaPropertyPrivate::setSignalExpression(const QDeclarativeMetaPrope
}
}
-QMetaMethod QDeclarativeMetaPropertyPrivate::findSignal(QObject *obj, const QString &name)
-{
- const QMetaObject *mo = obj->metaObject();
-
- int methods = mo->methodCount();
- for (int ii = methods - 1; ii >= 0; --ii) {
- QMetaMethod method = mo->method(ii);
- QString methodName = QString::fromUtf8(method.signature());
- int idx = methodName.indexOf(QLatin1Char('('));
- methodName = methodName.left(idx);
-
- if (methodName == name)
- return method;
- }
- return QMetaMethod();
-}
-
/*!
Returns the property value.
*/
-QVariant QDeclarativeMetaProperty::read() const
+QVariant QDeclarativeProperty::read() const
{
if (!d->object)
return QVariant();
@@ -723,10 +752,48 @@ QVariant QDeclarativeMetaProperty::read() const
return QVariant();
}
-QVariant QDeclarativeMetaPropertyPrivate::readValueProperty()
+/*!
+Return the \a name property value of \a object. This method is equivalent to:
+\code
+ QDeclarativeProperty p(object, name);
+ p.read();
+\endcode
+*/
+QVariant QDeclarativeProperty::read(QObject *object, const QString &name)
{
- uint type = q->type();
- if(type & QDeclarativeMetaProperty::ValueTypeProperty) {
+ QDeclarativeProperty p(object, name);
+ return p.read();
+}
+
+/*!
+Return the \a name property value of \a object. This method is equivalent to:
+\code
+ QDeclarativeProperty p(object, name, context);
+ p.read();
+\endcode
+*/
+QVariant QDeclarativeProperty::read(QObject *object, const QString &name, QDeclarativeContext *ctxt)
+{
+ QDeclarativeProperty p(object, name, ctxt);
+ return p.read();
+}
+
+/*!
+Return the \a name property value of \a object. This method is equivalent to:
+\code
+ QDeclarativeProperty p(object, name, engine);
+ p.read();
+\endcode
+*/
+QVariant QDeclarativeProperty::read(QObject *object, const QString &name, QDeclarativeEngine *engine)
+{
+ QDeclarativeProperty p(object, name, engine);
+ return p.read();
+}
+
+QVariant QDeclarativePropertyPrivate::readValueProperty()
+{
+ if(isValueType()) {
QDeclarativeEnginePrivate *ep = QDeclarativeEnginePrivate::get(context);
QDeclarativeValueType *valueType = 0;
@@ -747,7 +814,7 @@ QVariant QDeclarativeMetaPropertyPrivate::readValueProperty()
QDeclarativeListProperty<QObject> prop;
void *args[] = { &prop, 0 };
QMetaObject::metacall(object, QMetaObject::ReadProperty, core.coreIndex, args);
- return QVariant::fromValue(QDeclarativeListReferencePrivate::init(prop, core.propType, context?context->engine():0));
+ return QVariant::fromValue(QDeclarativeListReferencePrivate::init(prop, core.propType, engine));
} else {
@@ -756,10 +823,8 @@ QVariant QDeclarativeMetaPropertyPrivate::readValueProperty()
}
}
-//###
//writeEnumProperty MIRRORS the relelvant bit of QMetaProperty::write AND MUST BE KEPT IN SYNC!
-//###
-bool QDeclarativeMetaPropertyPrivate::writeEnumProperty(const QMetaProperty &prop, int idx, QObject *object, const QVariant &value, int flags)
+bool QDeclarativePropertyPrivate::writeEnumProperty(const QMetaProperty &prop, int idx, QObject *object, const QVariant &value, int flags)
{
if (!object || !prop.isWritable())
return false;
@@ -796,7 +861,7 @@ bool QDeclarativeMetaPropertyPrivate::writeEnumProperty(const QMetaProperty &pro
return status;
}
-bool QDeclarativeMetaPropertyPrivate::writeValueProperty(const QVariant &value, WriteFlags flags)
+bool QDeclarativePropertyPrivate::writeValueProperty(const QVariant &value, WriteFlags flags)
{
// Remove any existing bindings on this property
if (!(flags & DontRemoveBinding)) {
@@ -805,8 +870,7 @@ bool QDeclarativeMetaPropertyPrivate::writeValueProperty(const QVariant &value,
}
bool rv = false;
- uint type = q->type();
- if (type & QDeclarativeMetaProperty::ValueTypeProperty) {
+ if (isValueType()) {
QDeclarativeEnginePrivate *ep = QDeclarativeEnginePrivate::get(context);
QDeclarativeValueType *writeBack = 0;
@@ -836,7 +900,7 @@ bool QDeclarativeMetaPropertyPrivate::writeValueProperty(const QVariant &value,
return rv;
}
-bool QDeclarativeMetaPropertyPrivate::write(QObject *object, const QDeclarativePropertyCache::Data &property,
+bool QDeclarativePropertyPrivate::write(QObject *object, const QDeclarativePropertyCache::Data &property,
const QVariant &value, QDeclarativeContext *context,
WriteFlags flags)
{
@@ -947,13 +1011,13 @@ bool QDeclarativeMetaPropertyPrivate::write(QObject *object, const QDeclarativeP
for (int ii = 0; ii < list.count(); ++ii) {
QObject *o = list.at(ii);
- if (!canConvert(o->metaObject(), listType))
+ if (o && !canConvert(o->metaObject(), listType))
o = 0;
prop.append(&prop, (void *)o);
}
} else {
QObject *o = enginePriv?enginePriv->toQObject(value):QDeclarativeMetaType::toQObject(value);
- if (!canConvert(o->metaObject(), listType))
+ if (o && !canConvert(o->metaObject(), listType))
o = 0;
prop.append(&prop, (void *)o);
}
@@ -991,7 +1055,7 @@ bool QDeclarativeMetaPropertyPrivate::write(QObject *object, const QDeclarativeP
return true;
}
-const QMetaObject *QDeclarativeMetaPropertyPrivate::rawMetaObjectForType(QDeclarativeEnginePrivate *engine, int userType)
+const QMetaObject *QDeclarativePropertyPrivate::rawMetaObjectForType(QDeclarativeEnginePrivate *engine, int userType)
{
if (engine) {
return engine->rawMetaObjectForType(userType);
@@ -1004,15 +1068,56 @@ const QMetaObject *QDeclarativeMetaPropertyPrivate::rawMetaObjectForType(QDeclar
/*!
Set the property value to \a value.
*/
-bool QDeclarativeMetaProperty::write(const QVariant &value) const
+bool QDeclarativeProperty::write(const QVariant &value) const
{
- return QDeclarativeMetaPropertyPrivate::write(*this, value, 0);
+ return QDeclarativePropertyPrivate::write(*this, value, 0);
+}
+
+/*!
+Writes \a value to the \a name property of \a object. This method is equivalent to:
+\code
+ QDeclarativeProperty p(object, name);
+ p.write(value);
+\endcode
+*/
+bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVariant &value)
+{
+ QDeclarativeProperty p(object, name);
+ return p.write(value);
+}
+
+/*!
+Writes \a value to the \a name property of \a object. This method is equivalent to:
+\code
+ QDeclarativeProperty p(object, name, ctxt);
+ p.write(value);
+\endcode
+*/
+bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVariant &value,
+ QDeclarativeContext *ctxt)
+{
+ QDeclarativeProperty p(object, name, ctxt);
+ return p.write(value);
+}
+
+/*!
+Writes \a value to the \a name property of \a object. This method is equivalent to:
+\code
+ QDeclarativeProperty p(object, name, engine);
+ p.write(value);
+\endcode
+*/
+bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVariant &value,
+ QDeclarativeEngine *engine)
+{
+ QDeclarativeProperty p(object, name, engine);
+ return p.write(value);
}
/*!
Resets the property value.
*/
-bool QDeclarativeMetaProperty::reset() const
+bool QDeclarativeProperty::reset() const
{
if (isResettable()) {
void *args[] = { 0 };
@@ -1023,10 +1128,10 @@ bool QDeclarativeMetaProperty::reset() const
}
}
-bool QDeclarativeMetaPropertyPrivate::write(const QDeclarativeMetaProperty &that,
+bool QDeclarativePropertyPrivate::write(const QDeclarativeProperty &that,
const QVariant &value, WriteFlags flags)
{
- if (that.d->object && that.type() & QDeclarativeMetaProperty::Property &&
+ if (that.d->object && that.type() & QDeclarativeProperty::Property &&
that.d->core.isValid() && that.isWritable())
return that.d->writeValueProperty(value, flags);
else
@@ -1036,7 +1141,7 @@ bool QDeclarativeMetaPropertyPrivate::write(const QDeclarativeMetaProperty &that
/*!
Returns true if the property has a change notifier signal, otherwise false.
*/
-bool QDeclarativeMetaProperty::hasChangedNotifier() const
+bool QDeclarativeProperty::hasNotifySignal() const
{
if (type() & Property && d->object) {
return d->object->metaObject()->property(d->core.coreIndex).hasNotifySignal();
@@ -1051,7 +1156,7 @@ bool QDeclarativeMetaProperty::hasChangedNotifier() const
Some properties, such as attached properties or those whose value never
changes, do not require a change notifier.
*/
-bool QDeclarativeMetaProperty::needsChangedNotifier() const
+bool QDeclarativeProperty::needsNotifySignal() const
{
return type() & Property && !property().isConstant();
}
@@ -1064,7 +1169,7 @@ bool QDeclarativeMetaProperty::needsChangedNotifier() const
change notifier signal, or if the \a dest object does
not have the specified \a method.
*/
-bool QDeclarativeMetaProperty::connectNotifier(QObject *dest, int method) const
+bool QDeclarativeProperty::connectNotifySignal(QObject *dest, int method) const
{
if (!(type() & Property) || !d->object)
return false;
@@ -1085,7 +1190,7 @@ bool QDeclarativeMetaProperty::connectNotifier(QObject *dest, int method) const
change notifier signal, or if the \a dest object does
not have the specified \a slot.
*/
-bool QDeclarativeMetaProperty::connectNotifier(QObject *dest, const char *slot) const
+bool QDeclarativeProperty::connectNotifySignal(QObject *dest, const char *slot) const
{
if (!(type() & Property) || !d->object)
return false;
@@ -1102,18 +1207,18 @@ bool QDeclarativeMetaProperty::connectNotifier(QObject *dest, const char *slot)
/*!
Return the Qt metaobject index of the property.
*/
-int QDeclarativeMetaProperty::coreIndex() const
+int QDeclarativeProperty::index() const
{
return d->core.coreIndex;
}
-int QDeclarativeMetaPropertyPrivate::valueTypeCoreIndex(const QDeclarativeMetaProperty &that)
+int QDeclarativePropertyPrivate::valueTypeCoreIndex(const QDeclarativeProperty &that)
{
return that.d->valueType.valueTypeCoreIdx;
}
struct SerializedData {
- QDeclarativeMetaProperty::Type type;
+ bool isValueType;
QDeclarativePropertyCache::Data core;
};
@@ -1121,14 +1226,14 @@ struct ValueTypeSerializedData : public SerializedData {
QDeclarativePropertyCache::ValueTypeData valueType;
};
-QByteArray QDeclarativeMetaPropertyPrivate::saveValueType(const QMetaObject *metaObject, int index,
+QByteArray QDeclarativePropertyPrivate::saveValueType(const QMetaObject *metaObject, int index,
const QMetaObject *subObject, int subIndex)
{
QMetaProperty prop = metaObject->property(index);
QMetaProperty subProp = subObject->property(subIndex);
ValueTypeSerializedData sd;
- sd.type = QDeclarativeMetaProperty::ValueTypeProperty;
+ sd.isValueType = true;
sd.core.load(metaObject->property(index));
sd.valueType.flags = QDeclarativePropertyCache::Data::flagsForProperty(subProp);
sd.valueType.valueTypeCoreIdx = subIndex;
@@ -1139,34 +1244,35 @@ QByteArray QDeclarativeMetaPropertyPrivate::saveValueType(const QMetaObject *met
return rv;
}
-QByteArray QDeclarativeMetaPropertyPrivate::saveProperty(const QMetaObject *metaObject, int index)
+QByteArray QDeclarativePropertyPrivate::saveProperty(const QMetaObject *metaObject, int index)
{
SerializedData sd;
- sd.type = QDeclarativeMetaProperty::Property;
+ sd.isValueType = false;
sd.core.load(metaObject->property(index));
QByteArray rv((const char *)&sd, sizeof(sd));
return rv;
}
-QDeclarativeMetaProperty
-QDeclarativeMetaPropertyPrivate::restore(const QByteArray &data, QObject *object, QDeclarativeContext *ctxt)
+QDeclarativeProperty
+QDeclarativePropertyPrivate::restore(const QByteArray &data, QObject *object, QDeclarativeContext *ctxt)
{
- QDeclarativeMetaProperty prop;
+ QDeclarativeProperty prop;
if (data.isEmpty())
return prop;
prop.d->object = object;
prop.d->context = ctxt;
+ prop.d->engine = ctxt?ctxt->engine():0;
const SerializedData *sd = (const SerializedData *)data.constData();
- if (sd->type == QDeclarativeMetaProperty::Property) {
- prop.d->core = sd->core;
- } else if(sd->type == QDeclarativeMetaProperty::ValueTypeProperty) {
+ if (sd->isValueType) {
const ValueTypeSerializedData *vt = (const ValueTypeSerializedData *)sd;
prop.d->core = vt->core;
prop.d->valueType = vt->valueType;
+ } else {
+ prop.d->core = sd->core;
}
return prop;
@@ -1175,7 +1281,7 @@ QDeclarativeMetaPropertyPrivate::restore(const QByteArray &data, QObject *object
/*!
Returns true if lhs and rhs refer to the same metaobject data
*/
-bool QDeclarativeMetaPropertyPrivate::equal(const QMetaObject *lhs, const QMetaObject *rhs)
+bool QDeclarativePropertyPrivate::equal(const QMetaObject *lhs, const QMetaObject *rhs)
{
return lhs == rhs || (1 && lhs && rhs && lhs->d.stringdata == rhs->d.stringdata);
}
@@ -1183,7 +1289,7 @@ bool QDeclarativeMetaPropertyPrivate::equal(const QMetaObject *lhs, const QMetaO
/*!
Returns true if from inherits to.
*/
-bool QDeclarativeMetaPropertyPrivate::canConvert(const QMetaObject *from, const QMetaObject *to)
+bool QDeclarativePropertyPrivate::canConvert(const QMetaObject *from, const QMetaObject *to)
{
if (from && to == &QObject::staticMetaObject)
return true;
diff --git a/src/declarative/qml/qdeclarativemetaproperty.h b/src/declarative/qml/qdeclarativeproperty.h
index 828749f..73bccf3 100644
--- a/src/declarative/qml/qdeclarativemetaproperty.h
+++ b/src/declarative/qml/qdeclarativeproperty.h
@@ -39,8 +39,8 @@
**
****************************************************************************/
-#ifndef QDECLARATIVEMETAPROPERTY_H
-#define QDECLARATIVEMETAPROPERTY_H
+#ifndef QDECLARATIVEPROPERTY_H
+#define QDECLARATIVEPROPERTY_H
#include <QtCore/qmetaobject.h>
@@ -51,16 +51,12 @@ QT_BEGIN_NAMESPACE
QT_MODULE(Declarative)
class QObject;
-class QDeclarativeAbstractBinding;
-class QDeclarativeExpression;
-class QStringList;
class QVariant;
-struct QMetaObject;
class QDeclarativeContext;
class QDeclarativeEngine;
-class QDeclarativeMetaPropertyPrivate;
-class Q_DECLARATIVE_EXPORT QDeclarativeMetaProperty
+class QDeclarativePropertyPrivate;
+class Q_DECLARATIVE_EXPORT QDeclarativeProperty
{
public:
enum PropertyTypeCategory {
@@ -70,64 +66,73 @@ public:
Normal
};
- enum Type { Invalid = 0x00,
- Property = 0x01,
- SignalProperty = 0x02,
- Default = 0x08,
- ValueTypeProperty = 0x10
+ enum Type {
+ Invalid,
+ Property,
+ SignalProperty
};
- QDeclarativeMetaProperty();
- ~QDeclarativeMetaProperty();
+ QDeclarativeProperty();
+ ~QDeclarativeProperty();
- QDeclarativeMetaProperty(QObject *);
- QDeclarativeMetaProperty(QObject *, QDeclarativeContext *);
+ QDeclarativeProperty(QObject *);
+ QDeclarativeProperty(QObject *, QDeclarativeContext *);
+ QDeclarativeProperty(QObject *, QDeclarativeEngine *);
- QDeclarativeMetaProperty(QObject *, const QString &);
- QDeclarativeMetaProperty(QObject *, const QString &, QDeclarativeContext *);
+ QDeclarativeProperty(QObject *, const QString &);
+ QDeclarativeProperty(QObject *, const QString &, QDeclarativeContext *);
+ QDeclarativeProperty(QObject *, const QString &, QDeclarativeEngine *);
- QDeclarativeMetaProperty(const QDeclarativeMetaProperty &);
- QDeclarativeMetaProperty &operator=(const QDeclarativeMetaProperty &);
+ QDeclarativeProperty(const QDeclarativeProperty &);
+ QDeclarativeProperty &operator=(const QDeclarativeProperty &);
+
+ bool operator==(const QDeclarativeProperty &) const;
+
+ Type type() const;
+ bool isValid() const;
+ bool isProperty() const;
+ bool isSignalProperty() const;
+
+ int propertyType() const;
+ PropertyTypeCategory propertyTypeCategory() const;
+ const char *propertyTypeName() const;
QString name() const;
QVariant read() const;
+ static QVariant read(QObject *, const QString &);
+ static QVariant read(QObject *, const QString &, QDeclarativeContext *);
+ static QVariant read(QObject *, const QString &, QDeclarativeEngine *);
+
bool write(const QVariant &) const;
+ static bool write(QObject *, const QString &, const QVariant &);
+ static bool write(QObject *, const QString &, const QVariant &, QDeclarativeContext *);
+ static bool write(QObject *, const QString &, const QVariant &, QDeclarativeEngine *);
+
bool reset() const;
- bool hasChangedNotifier() const;
- bool needsChangedNotifier() const;
- bool connectNotifier(QObject *dest, const char *slot) const;
- bool connectNotifier(QObject *dest, int method) const;
+ bool hasNotifySignal() const;
+ bool needsNotifySignal() const;
+ bool connectNotifySignal(QObject *dest, const char *slot) const;
+ bool connectNotifySignal(QObject *dest, int method) const;
- Type type() const;
- bool isProperty() const;
- bool isDefault() const;
bool isWritable() const;
bool isDesignable() const;
bool isResettable() const;
- bool isValid() const;
QObject *object() const;
- int propertyType() const;
- PropertyTypeCategory propertyTypeCategory() const;
- const char *propertyTypeName() const;
-
- bool operator==(const QDeclarativeMetaProperty &) const;
-
- int coreIndex() const;
+ int index() const;
QMetaProperty property() const;
QMetaMethod method() const;
private:
- friend class QDeclarativeEnginePrivate;
- friend class QDeclarativeMetaPropertyPrivate;
- QDeclarativeMetaPropertyPrivate *d;
+ friend class QDeclarativePropertyPrivate;
+ QDeclarativePropertyPrivate *d;
};
-typedef QList<QDeclarativeMetaProperty> QDeclarativeMetaProperties;
+typedef QList<QDeclarativeProperty> QDeclarativeProperties;
QT_END_NAMESPACE
QT_END_HEADER
-#endif // QDECLARATIVEMETAPROPERTY_H
+#endif // QDECLARATIVEPROPERTY_H
diff --git a/src/declarative/qml/qdeclarativemetaproperty_p.h b/src/declarative/qml/qdeclarativeproperty_p.h
index a171545..1fda7f4 100644
--- a/src/declarative/qml/qdeclarativemetaproperty_p.h
+++ b/src/declarative/qml/qdeclarativeproperty_p.h
@@ -39,8 +39,8 @@
**
****************************************************************************/
-#ifndef QDECLARATIVEMETAPROPERTY_P_H
-#define QDECLARATIVEMETAPROPERTY_P_H
+#ifndef QDECLARATIVEPROPERTY_P_H
+#define QDECLARATIVEPROPERTY_P_H
//
// W A R N I N G
@@ -53,7 +53,7 @@
// We mean it.
//
-#include "qdeclarativemetaproperty.h"
+#include "qdeclarativeproperty.h"
#include "qdeclarativepropertycache_p.h"
#include "qdeclarativeguard_p.h"
@@ -64,27 +64,28 @@ QT_BEGIN_NAMESPACE
class QDeclarativeContext;
class QDeclarativeEnginePrivate;
-class Q_AUTOTEST_EXPORT QDeclarativeMetaPropertyPrivate
+class QDeclarativeExpression;
+class Q_AUTOTEST_EXPORT QDeclarativePropertyPrivate
{
public:
enum WriteFlag { BypassInterceptor = 0x01, DontRemoveBinding = 0x02 };
Q_DECLARE_FLAGS(WriteFlags, WriteFlag)
- QDeclarativeMetaPropertyPrivate()
- : q(0), context(0), object(0), isDefaultProperty(false), isNameCached(false) {}
+ QDeclarativePropertyPrivate()
+ : q(0), context(0), engine(0), object(0), isNameCached(false) {}
- QDeclarativeMetaPropertyPrivate(const QDeclarativeMetaPropertyPrivate &other)
- : q(0), context(other.context), object(other.object),
- isDefaultProperty(other.isDefaultProperty), isNameCached(other.isNameCached),
+ QDeclarativePropertyPrivate(const QDeclarativePropertyPrivate &other)
+ : q(0), context(other.context), engine(other.engine), object(other.object),
+ isNameCached(other.isNameCached),
core(other.core), nameCache(other.nameCache),
valueType(other.valueType) {}
- QDeclarativeMetaProperty *q;
+ QDeclarativeProperty *q;
QDeclarativeContext *context;
+ QDeclarativeEngine *engine;
QDeclarativeGuard<QObject> object;
- bool isDefaultProperty:1;
bool isNameCached:1;
QDeclarativePropertyCache::Data core;
QString nameCache;
@@ -97,8 +98,9 @@ public:
QMetaMethod findSignal(QObject *, const QString &);
+ bool isValueType() const;
int propertyType() const;
- QDeclarativeMetaProperty::PropertyTypeCategory propertyTypeCategory() const;
+ QDeclarativeProperty::PropertyTypeCategory propertyTypeCategory() const;
QVariant readValueProperty();
bool writeValueProperty(const QVariant &, WriteFlags);
@@ -115,26 +117,26 @@ public:
static QByteArray saveValueType(const QMetaObject *, int,
const QMetaObject *, int);
static QByteArray saveProperty(const QMetaObject *, int);
- static QDeclarativeMetaProperty restore(const QByteArray &, QObject *, QDeclarativeContext *);
+ static QDeclarativeProperty restore(const QByteArray &, QObject *, QDeclarativeContext *);
static bool equal(const QMetaObject *, const QMetaObject *);
static bool canConvert(const QMetaObject *from, const QMetaObject *to);
// "Public" (to QML) methods
- static QDeclarativeAbstractBinding *binding(const QDeclarativeMetaProperty &that);
- static QDeclarativeAbstractBinding *setBinding(const QDeclarativeMetaProperty &that,
+ static QDeclarativeAbstractBinding *binding(const QDeclarativeProperty &that);
+ static QDeclarativeAbstractBinding *setBinding(const QDeclarativeProperty &that,
QDeclarativeAbstractBinding *,
WriteFlags flags = DontRemoveBinding);
- static QDeclarativeExpression *signalExpression(const QDeclarativeMetaProperty &that);
- static QDeclarativeExpression *setSignalExpression(const QDeclarativeMetaProperty &that,
+ static QDeclarativeExpression *signalExpression(const QDeclarativeProperty &that);
+ static QDeclarativeExpression *setSignalExpression(const QDeclarativeProperty &that,
QDeclarativeExpression *) ;
- static bool write(const QDeclarativeMetaProperty &that, const QVariant &, WriteFlags);
- static int valueTypeCoreIndex(const QDeclarativeMetaProperty &that);
+ static bool write(const QDeclarativeProperty &that, const QVariant &, WriteFlags);
+ static int valueTypeCoreIndex(const QDeclarativeProperty &that);
};
-Q_DECLARE_OPERATORS_FOR_FLAGS(QDeclarativeMetaPropertyPrivate::WriteFlags)
+Q_DECLARE_OPERATORS_FOR_FLAGS(QDeclarativePropertyPrivate::WriteFlags)
QT_END_NAMESPACE
-#endif // QDECLARATIVEMETAPROPERTY_P_H
+#endif // QDECLARATIVEPROPERTY_P_H
diff --git a/src/declarative/qml/qdeclarativepropertyvalueinterceptor.cpp b/src/declarative/qml/qdeclarativepropertyvalueinterceptor.cpp
index 7626d56..3f6d805 100644
--- a/src/declarative/qml/qdeclarativepropertyvalueinterceptor.cpp
+++ b/src/declarative/qml/qdeclarativepropertyvalueinterceptor.cpp
@@ -66,7 +66,7 @@ QDeclarativePropertyValueInterceptor::~QDeclarativePropertyValueInterceptor()
}
/*!
- \fn void QDeclarativePropertyValueInterceptor::setTarget(const QDeclarativeMetaProperty &property)
+ \fn void QDeclarativePropertyValueInterceptor::setTarget(const QDeclarativeProperty &property)
Set the target \a property for the value interceptor. This method will
be called by the QML engine when assigning a value interceptor.
*/
diff --git a/src/declarative/qml/qdeclarativepropertyvalueinterceptor.h b/src/declarative/qml/qdeclarativepropertyvalueinterceptor.h
index 2a29d5b..3de5abc 100644
--- a/src/declarative/qml/qdeclarativepropertyvalueinterceptor.h
+++ b/src/declarative/qml/qdeclarativepropertyvalueinterceptor.h
@@ -50,13 +50,13 @@ QT_BEGIN_NAMESPACE
QT_MODULE(Declarative)
-class QDeclarativeMetaProperty;
+class QDeclarativeProperty;
class Q_DECLARATIVE_EXPORT QDeclarativePropertyValueInterceptor
{
public:
QDeclarativePropertyValueInterceptor();
virtual ~QDeclarativePropertyValueInterceptor();
- virtual void setTarget(const QDeclarativeMetaProperty &property) = 0;
+ virtual void setTarget(const QDeclarativeProperty &property) = 0;
virtual void write(const QVariant &value) = 0;
};
Q_DECLARE_INTERFACE(QDeclarativePropertyValueInterceptor, "com.trolltech.qml.QDeclarativePropertyValueInterceptor")
diff --git a/src/declarative/qml/qdeclarativepropertyvaluesource.cpp b/src/declarative/qml/qdeclarativepropertyvaluesource.cpp
index 626e391..b106d4f 100644
--- a/src/declarative/qml/qdeclarativepropertyvaluesource.cpp
+++ b/src/declarative/qml/qdeclarativepropertyvaluesource.cpp
@@ -63,7 +63,7 @@ QDeclarativePropertyValueSource::~QDeclarativePropertyValueSource()
}
/*!
- \fn void QDeclarativePropertyValueSource::setTarget(const QDeclarativeMetaProperty &property)
+ \fn void QDeclarativePropertyValueSource::setTarget(const QDeclarativeProperty &property)
Set the target \a property for the value source. This method will
be called by the QML engine when assigning a value source.
*/
diff --git a/src/declarative/qml/qdeclarativepropertyvaluesource.h b/src/declarative/qml/qdeclarativepropertyvaluesource.h
index 99c80af..70d2c03 100644
--- a/src/declarative/qml/qdeclarativepropertyvaluesource.h
+++ b/src/declarative/qml/qdeclarativepropertyvaluesource.h
@@ -50,13 +50,13 @@ QT_BEGIN_NAMESPACE
QT_MODULE(Declarative)
-class QDeclarativeMetaProperty;
+class QDeclarativeProperty;
class Q_DECLARATIVE_EXPORT QDeclarativePropertyValueSource
{
public:
QDeclarativePropertyValueSource();
virtual ~QDeclarativePropertyValueSource();
- virtual void setTarget(const QDeclarativeMetaProperty &) = 0;
+ virtual void setTarget(const QDeclarativeProperty &) = 0;
};
Q_DECLARE_INTERFACE(QDeclarativePropertyValueSource, "com.trolltech.qml.QDeclarativePropertyValueSource")
diff --git a/src/declarative/qml/qdeclarativescript.cpp b/src/declarative/qml/qdeclarativescript.cpp
index acfb9e1..ac4b2c1 100644
--- a/src/declarative/qml/qdeclarativescript.cpp
+++ b/src/declarative/qml/qdeclarativescript.cpp
@@ -43,6 +43,7 @@
/*!
\qmlclass Script QDeclarativeScript
+ \since 4.7
\brief The Script element provides a way to add JavaScript code snippets in QML.
\ingroup group_utility
diff --git a/src/declarative/qml/qdeclarativevaluetype.cpp b/src/declarative/qml/qdeclarativevaluetype.cpp
index d35371f..01fa214 100644
--- a/src/declarative/qml/qdeclarativevaluetype.cpp
+++ b/src/declarative/qml/qdeclarativevaluetype.cpp
@@ -100,7 +100,7 @@ void QDeclarativePointFValueType::read(QObject *obj, int idx)
QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);
}
-void QDeclarativePointFValueType::write(QObject *obj, int idx, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativePointFValueType::write(QObject *obj, int idx, QDeclarativePropertyPrivate::WriteFlags flags)
{
int status = -1;
void *a[] = { &point, 0, &status, &flags };
@@ -148,7 +148,7 @@ void QDeclarativePointValueType::read(QObject *obj, int idx)
QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);
}
-void QDeclarativePointValueType::write(QObject *obj, int idx, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativePointValueType::write(QObject *obj, int idx, QDeclarativePropertyPrivate::WriteFlags flags)
{
int status = -1;
void *a[] = { &point, 0, &status, &flags };
@@ -196,7 +196,7 @@ void QDeclarativeSizeFValueType::read(QObject *obj, int idx)
QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);
}
-void QDeclarativeSizeFValueType::write(QObject *obj, int idx, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeSizeFValueType::write(QObject *obj, int idx, QDeclarativePropertyPrivate::WriteFlags flags)
{
int status = -1;
void *a[] = { &size, 0, &status, &flags };
@@ -244,7 +244,7 @@ void QDeclarativeSizeValueType::read(QObject *obj, int idx)
QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);
}
-void QDeclarativeSizeValueType::write(QObject *obj, int idx, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeSizeValueType::write(QObject *obj, int idx, QDeclarativePropertyPrivate::WriteFlags flags)
{
int status = -1;
void *a[] = { &size, 0, &status, &flags };
@@ -292,7 +292,7 @@ void QDeclarativeRectFValueType::read(QObject *obj, int idx)
QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);
}
-void QDeclarativeRectFValueType::write(QObject *obj, int idx, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeRectFValueType::write(QObject *obj, int idx, QDeclarativePropertyPrivate::WriteFlags flags)
{
int status = -1;
void *a[] = { &rect, 0, &status, &flags };
@@ -360,7 +360,7 @@ void QDeclarativeRectValueType::read(QObject *obj, int idx)
QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);
}
-void QDeclarativeRectValueType::write(QObject *obj, int idx, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeRectValueType::write(QObject *obj, int idx, QDeclarativePropertyPrivate::WriteFlags flags)
{
int status = -1;
void *a[] = { &rect, 0, &status, &flags };
@@ -428,7 +428,7 @@ void QDeclarativeVector3DValueType::read(QObject *obj, int idx)
QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);
}
-void QDeclarativeVector3DValueType::write(QObject *obj, int idx, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeVector3DValueType::write(QObject *obj, int idx, QDeclarativePropertyPrivate::WriteFlags flags)
{
int status = -1;
void *a[] = { &vector, 0, &status, &flags };
@@ -486,7 +486,7 @@ void QDeclarativeEasingValueType::read(QObject *obj, int idx)
QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);
}
-void QDeclarativeEasingValueType::write(QObject *obj, int idx, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeEasingValueType::write(QObject *obj, int idx, QDeclarativePropertyPrivate::WriteFlags flags)
{
int status = -1;
void *a[] = { &easing, 0, &status, &flags };
@@ -554,7 +554,7 @@ void QDeclarativeFontValueType::read(QObject *obj, int idx)
QMetaObject::metacall(obj, QMetaObject::ReadProperty, idx, a);
}
-void QDeclarativeFontValueType::write(QObject *obj, int idx, QDeclarativeMetaPropertyPrivate::WriteFlags flags)
+void QDeclarativeFontValueType::write(QObject *obj, int idx, QDeclarativePropertyPrivate::WriteFlags flags)
{
int status = -1;
void *a[] = { &font, 0, &status, &flags };
diff --git a/src/declarative/qml/qdeclarativevaluetype_p.h b/src/declarative/qml/qdeclarativevaluetype_p.h
index 792598b..cb153be 100644
--- a/src/declarative/qml/qdeclarativevaluetype_p.h
+++ b/src/declarative/qml/qdeclarativevaluetype_p.h
@@ -53,8 +53,8 @@
// We mean it.
//
-#include "qdeclarativemetaproperty.h"
-#include "qdeclarativemetaproperty_p.h"
+#include "qdeclarativeproperty.h"
+#include "qdeclarativeproperty_p.h"
#include <QtCore/qobject.h>
#include <QtCore/qrect.h>
@@ -71,7 +71,7 @@ class Q_DECLARATIVE_EXPORT QDeclarativeValueType : public QObject
public:
QDeclarativeValueType(QObject *parent = 0);
virtual void read(QObject *, int) = 0;
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags flags) = 0;
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags flags) = 0;
virtual QVariant value() = 0;
virtual void setValue(QVariant) = 0;
};
@@ -96,7 +96,7 @@ public:
QDeclarativePointFValueType(QObject *parent = 0);
virtual void read(QObject *, int);
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags);
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags);
virtual QVariant value();
virtual void setValue(QVariant value);
@@ -118,7 +118,7 @@ public:
QDeclarativePointValueType(QObject *parent = 0);
virtual void read(QObject *, int);
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags);
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags);
virtual QVariant value();
virtual void setValue(QVariant value);
@@ -140,7 +140,7 @@ public:
QDeclarativeSizeFValueType(QObject *parent = 0);
virtual void read(QObject *, int);
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags);
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags);
virtual QVariant value();
virtual void setValue(QVariant value);
@@ -162,7 +162,7 @@ public:
QDeclarativeSizeValueType(QObject *parent = 0);
virtual void read(QObject *, int);
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags);
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags);
virtual QVariant value();
virtual void setValue(QVariant value);
@@ -186,7 +186,7 @@ public:
QDeclarativeRectFValueType(QObject *parent = 0);
virtual void read(QObject *, int);
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags);
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags);
virtual QVariant value();
virtual void setValue(QVariant value);
@@ -215,7 +215,7 @@ public:
QDeclarativeRectValueType(QObject *parent = 0);
virtual void read(QObject *, int);
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags);
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags);
virtual QVariant value();
virtual void setValue(QVariant value);
@@ -243,7 +243,7 @@ public:
QDeclarativeVector3DValueType(QObject *parent = 0);
virtual void read(QObject *, int);
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags);
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags);
virtual QVariant value();
virtual void setValue(QVariant value);
@@ -297,7 +297,7 @@ public:
QDeclarativeEasingValueType(QObject *parent = 0);
virtual void read(QObject *, int);
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags);
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags);
virtual QVariant value();
virtual void setValue(QVariant value);
@@ -348,7 +348,7 @@ public:
QDeclarativeFontValueType(QObject *parent = 0);
virtual void read(QObject *, int);
- virtual void write(QObject *, int, QDeclarativeMetaPropertyPrivate::WriteFlags);
+ virtual void write(QObject *, int, QDeclarativePropertyPrivate::WriteFlags);
virtual QVariant value();
virtual void setValue(QVariant value);
diff --git a/src/declarative/qml/qdeclarativevme.cpp b/src/declarative/qml/qdeclarativevme.cpp
index f7af843..fc3722d 100644
--- a/src/declarative/qml/qdeclarativevme.cpp
+++ b/src/declarative/qml/qdeclarativevme.cpp
@@ -156,7 +156,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEStack<QObject *> &stack, QDeclarati
QDeclarativeContextPrivate *cp = (QDeclarativeContextPrivate *)QObjectPrivate::get(ctxt);
int status = -1; //for dbus
- QDeclarativeMetaPropertyPrivate::WriteFlags flags = QDeclarativeMetaPropertyPrivate::BypassInterceptor;
+ QDeclarativePropertyPrivate::WriteFlags flags = QDeclarativePropertyPrivate::BypassInterceptor;
for (int ii = start; !isError() && ii < (start + count); ++ii) {
const QDeclarativeInstruction &instr = comp->bytecode.at(ii);
@@ -217,7 +217,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEStack<QObject *> &stack, QDeclarati
// TODO: parent might be a layout
}
} else {
- QDeclarativeGraphics_setParent_noEvent(o, parent);
+ QDeclarative_setParent_noEvent(o, parent);
// o->setParent(parent);
}
}
@@ -515,8 +515,8 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEStack<QObject *> &stack, QDeclarati
int sigIdx = instr.assignSignalObject.signal;
const QByteArray &pr = datas.at(sigIdx);
- QDeclarativeMetaProperty prop(target, QString::fromUtf8(pr));
- if (prop.type() & QDeclarativeMetaProperty::SignalProperty) {
+ QDeclarativeProperty prop(target, QString::fromUtf8(pr));
+ if (prop.type() & QDeclarativeProperty::SignalProperty) {
QMetaMethod method = QDeclarativeMetaType::defaultMethod(assign);
if (method.signature() == 0)
@@ -525,7 +525,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEStack<QObject *> &stack, QDeclarati
if (!QMetaObject::checkConnectArgs(prop.method().signature(), method.signature()))
VME_EXCEPTION(QCoreApplication::translate("QDeclarativeVME","Cannot connect mismatched signal/slot %1 %vs. %2").arg(QString::fromLatin1(method.signature())).arg(QString::fromLatin1(prop.method().signature())));
- QMetaObject::connect(target, prop.coreIndex(), assign, method.methodIndex());
+ QMetaObject::connect(target, prop.index(), assign, method.methodIndex());
} else {
VME_EXCEPTION(QCoreApplication::translate("QDeclarativeVME","Cannot assign an object to signal property %1").arg(QString::fromUtf8(pr)));
@@ -590,10 +590,10 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEStack<QObject *> &stack, QDeclarati
QObject *context =
stack.at(stack.count() - 1 - instr.assignBinding.context);
- QDeclarativeMetaProperty mp =
- QDeclarativeMetaPropertyPrivate::restore(datas.at(instr.assignBinding.property), target, ctxt);
+ QDeclarativeProperty mp =
+ QDeclarativePropertyPrivate::restore(datas.at(instr.assignBinding.property), target, ctxt);
- int coreIndex = mp.coreIndex();
+ int coreIndex = mp.index();
if (stack.count() == 1 && bindingSkipList.testBit(coreIndex))
break;
@@ -631,8 +631,8 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEStack<QObject *> &stack, QDeclarati
QDeclarativePropertyValueSource *vs = reinterpret_cast<QDeclarativePropertyValueSource *>(reinterpret_cast<char *>(obj) + instr.assignValueSource.castValue);
QObject *target = stack.at(stack.count() - 1 - instr.assignValueSource.owner);
- QDeclarativeMetaProperty prop =
- QDeclarativeMetaPropertyPrivate::restore(datas.at(instr.assignValueSource.property), target, ctxt);
+ QDeclarativeProperty prop =
+ QDeclarativePropertyPrivate::restore(datas.at(instr.assignValueSource.property), target, ctxt);
obj->setParent(target);
vs->setTarget(prop);
}
@@ -643,12 +643,12 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEStack<QObject *> &stack, QDeclarati
QObject *obj = stack.pop();
QDeclarativePropertyValueInterceptor *vi = reinterpret_cast<QDeclarativePropertyValueInterceptor *>(reinterpret_cast<char *>(obj) + instr.assignValueInterceptor.castValue);
QObject *target = stack.at(stack.count() - 1 - instr.assignValueInterceptor.owner);
- QDeclarativeMetaProperty prop =
- QDeclarativeMetaPropertyPrivate::restore(datas.at(instr.assignValueInterceptor.property), target, ctxt);
+ QDeclarativeProperty prop =
+ QDeclarativePropertyPrivate::restore(datas.at(instr.assignValueInterceptor.property), target, ctxt);
obj->setParent(target);
vi->setTarget(prop);
QDeclarativeVMEMetaObject *mo = static_cast<QDeclarativeVMEMetaObject *>((QMetaObject*)target->metaObject());
- mo->registerInterceptor(prop.coreIndex(), QDeclarativeMetaPropertyPrivate::valueTypeCoreIndex(prop), vi);
+ mo->registerInterceptor(prop.index(), QDeclarativePropertyPrivate::valueTypeCoreIndex(prop), vi);
}
break;
@@ -807,7 +807,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEStack<QObject *> &stack, QDeclarati
static_cast<QDeclarativeValueType *>(stack.pop());
QObject *target = stack.top();
valueHandler->write(target, instr.fetchValue.property,
- QDeclarativeMetaPropertyPrivate::BypassInterceptor);
+ QDeclarativePropertyPrivate::BypassInterceptor);
}
break;
diff --git a/src/declarative/qml/qdeclarativevmemetaobject.cpp b/src/declarative/qml/qdeclarativevmemetaobject.cpp
index 6edb707..d67c834 100644
--- a/src/declarative/qml/qdeclarativevmemetaobject.cpp
+++ b/src/declarative/qml/qdeclarativevmemetaobject.cpp
@@ -105,7 +105,7 @@ int QDeclarativeVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
int id = _id;
if(c == QMetaObject::WriteProperty) {
int flags = *reinterpret_cast<int*>(a[3]);
- if (!(flags & QDeclarativeMetaPropertyPrivate::BypassInterceptor)
+ if (!(flags & QDeclarativePropertyPrivate::BypassInterceptor)
&& !aInterceptors.isEmpty()
&& aInterceptors.testBit(id)) {
QPair<int, QDeclarativePropertyValueInterceptor*> pair = interceptors.value(id);
diff --git a/src/declarative/qml/qml.pri b/src/declarative/qml/qml.pri
index 8a43cec..aa1a34b 100644
--- a/src/declarative/qml/qml.pri
+++ b/src/declarative/qml/qml.pri
@@ -6,7 +6,7 @@ SOURCES += \
$$PWD/qdeclarativeengine.cpp \
$$PWD/qdeclarativeexpression.cpp \
$$PWD/qdeclarativebinding.cpp \
- $$PWD/qdeclarativemetaproperty.cpp \
+ $$PWD/qdeclarativeproperty.cpp \
$$PWD/qdeclarativecomponent.cpp \
$$PWD/qdeclarativecontext.cpp \
$$PWD/qdeclarativecustomparser.cpp \
@@ -62,7 +62,7 @@ HEADERS += \
$$PWD/qdeclarative.h \
$$PWD/qdeclarativebinding_p.h \
$$PWD/qdeclarativebinding_p_p.h \
- $$PWD/qdeclarativemetaproperty.h \
+ $$PWD/qdeclarativeproperty.h \
$$PWD/qdeclarativecomponent.h \
$$PWD/qdeclarativecomponent_p.h \
$$PWD/qdeclarativecustomparser_p.h \
@@ -87,7 +87,7 @@ HEADERS += \
$$PWD/qdeclarativestringconverters_p.h \
$$PWD/qdeclarativeclassfactory_p.h \
$$PWD/qdeclarativeinfo.h \
- $$PWD/qdeclarativemetaproperty_p.h \
+ $$PWD/qdeclarativeproperty_p.h \
$$PWD/qdeclarativecontext_p.h \
$$PWD/qdeclarativecompositetypedata_p.h \
$$PWD/qdeclarativecompositetypemanager_p.h \
diff --git a/src/declarative/util/qdeclarativeanimation.cpp b/src/declarative/util/qdeclarativeanimation.cpp
index a327ccb..10230d3 100644
--- a/src/declarative/util/qdeclarativeanimation.cpp
+++ b/src/declarative/util/qdeclarativeanimation.cpp
@@ -52,7 +52,7 @@
#include <qdeclarativestringconverters_p.h>
#include <qdeclarativeglobal_p.h>
#include <qdeclarativemetatype_p.h>
-#include <qdeclarativemetaproperty_p.h>
+#include <qdeclarativeproperty_p.h>
#include <qvariant.h>
#include <qcolor.h>
@@ -63,6 +63,7 @@
#include <QtCore/qrect.h>
#include <QtCore/qpoint.h>
#include <QtCore/qsize.h>
+#include <QtCore/qmath.h>
#include <private/qvariantanimation_p.h>
@@ -70,7 +71,7 @@ QT_BEGIN_NAMESPACE
/*!
\qmlclass Animation QDeclarativeAbstractAnimation
- \since 4.7
+ \since 4.7
\brief The Animation element is the base of all QML animations.
The Animation element cannot be used directly in a QML file. It exists
@@ -145,7 +146,7 @@ void QDeclarativeAbstractAnimationPrivate::commence()
Q_Q(QDeclarativeAbstractAnimation);
QDeclarativeStateActions actions;
- QDeclarativeMetaProperties properties;
+ QDeclarativeProperties properties;
q->transition(actions, properties, QDeclarativeAbstractAnimation::Forward);
q->qtAnimation()->start();
@@ -155,15 +156,15 @@ void QDeclarativeAbstractAnimationPrivate::commence()
}
}
-QDeclarativeMetaProperty QDeclarativeAbstractAnimationPrivate::createProperty(QObject *obj, const QString &str, QObject *infoObj)
+QDeclarativeProperty QDeclarativeAbstractAnimationPrivate::createProperty(QObject *obj, const QString &str, QObject *infoObj)
{
- QDeclarativeMetaProperty prop(obj, str, qmlContext(infoObj));
+ QDeclarativeProperty prop(obj, str, qmlContext(infoObj));
if (!prop.isValid()) {
qmlInfo(infoObj) << QDeclarativeAbstractAnimation::tr("Cannot animate non-existent property \"%1\"").arg(str);
- return QDeclarativeMetaProperty();
+ return QDeclarativeProperty();
} else if (!prop.isWritable()) {
qmlInfo(infoObj) << QDeclarativeAbstractAnimation::tr("Cannot animate read-only property \"%1\"").arg(str);
- return QDeclarativeMetaProperty();
+ return QDeclarativeProperty();
}
return prop;
}
@@ -360,9 +361,6 @@ void QDeclarativeAbstractAnimation::setGroup(QDeclarativeAnimationGroup *g)
if (d->group && !static_cast<QDeclarativeAnimationGroupPrivate *>(d->group->d_func())->animations.contains(this))
static_cast<QDeclarativeAnimationGroupPrivate *>(d->group->d_func())->animations.append(this);
- if (d->group)
- ((QAnimationGroup*)d->group->qtAnimation())->addAnimation(qtAnimation());
-
//if (g) //if removed from a group, then the group should no longer be the parent
setParent(g);
}
@@ -466,7 +464,7 @@ void QDeclarativeAbstractAnimation::complete()
}
}
-void QDeclarativeAbstractAnimation::setTarget(const QDeclarativeMetaProperty &p)
+void QDeclarativeAbstractAnimation::setTarget(const QDeclarativeProperty &p)
{
Q_D(QDeclarativeAbstractAnimation);
d->defaultProperty = p;
@@ -480,7 +478,7 @@ void QDeclarativeAbstractAnimation::setTarget(const QDeclarativeMetaProperty &p)
so this function allows us to do the same thing as setTarget without
that assumption
*/
-void QDeclarativeAbstractAnimation::setDefaultTarget(const QDeclarativeMetaProperty &p)
+void QDeclarativeAbstractAnimation::setDefaultTarget(const QDeclarativeProperty &p)
{
Q_D(QDeclarativeAbstractAnimation);
d->defaultProperty = p;
@@ -498,7 +496,7 @@ void QDeclarativeAbstractAnimation::setDisableUserControl()
}
void QDeclarativeAbstractAnimation::transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction)
{
Q_UNUSED(actions);
@@ -517,7 +515,7 @@ void QDeclarativeAbstractAnimation::timelineComplete()
/*!
\qmlclass PauseAnimation QDeclarativePauseAnimation
- \since 4.7
+ \since 4.7
\inherits Animation
\brief The PauseAnimation element provides a pause for an animation.
@@ -554,7 +552,7 @@ void QDeclarativePauseAnimationPrivate::init()
{
Q_Q(QDeclarativePauseAnimation);
pa = new QPauseAnimation;
- QDeclarativeGraphics_setParent_noEvent(pa, q);
+ QDeclarative_setParent_noEvent(pa, q);
}
/*!
@@ -591,7 +589,7 @@ QAbstractAnimation *QDeclarativePauseAnimation::qtAnimation()
/*!
\qmlclass ColorAnimation QDeclarativeColorAnimation
- \since 4.7
+ \since 4.7
\inherits PropertyAnimation
\brief The ColorAnimation element allows you to animate color changes.
@@ -655,7 +653,7 @@ void QDeclarativeColorAnimation::setTo(const QColor &t)
/*!
\qmlclass ScriptAction QDeclarativeScriptAction
- \since 4.7
+ \since 4.7
\inherits Animation
\brief The ScriptAction element allows scripts to be run during an animation.
@@ -679,7 +677,7 @@ void QDeclarativeScriptActionPrivate::init()
{
Q_Q(QDeclarativeScriptAction);
rsa = new QActionAnimation(&proxy);
- QDeclarativeGraphics_setParent_noEvent(rsa, q);
+ QDeclarative_setParent_noEvent(rsa, q);
}
/*!
@@ -729,7 +727,7 @@ void QDeclarativeScriptActionPrivate::execute()
}
void QDeclarativeScriptAction::transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction)
{
Q_D(QDeclarativeScriptAction);
@@ -761,7 +759,7 @@ QAbstractAnimation *QDeclarativeScriptAction::qtAnimation()
/*!
\qmlclass PropertyAction QDeclarativePropertyAction
- \since 4.7
+ \since 4.7
\inherits Animation
\brief The PropertyAction element allows immediate property changes during animation.
@@ -797,7 +795,7 @@ void QDeclarativePropertyActionPrivate::init()
{
Q_Q(QDeclarativePropertyAction);
spa = new QActionAnimation;
- QDeclarativeGraphics_setParent_noEvent(spa, q);
+ QDeclarative_setParent_noEvent(spa, q);
}
/*!
@@ -912,7 +910,7 @@ QAbstractAnimation *QDeclarativePropertyAction::qtAnimation()
}
void QDeclarativePropertyAction::transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction)
{
Q_D(QDeclarativePropertyAction);
@@ -925,7 +923,7 @@ void QDeclarativePropertyAction::transition(QDeclarativeStateActions &actions,
{
for (int ii = 0; ii < actions.count(); ++ii) {
const QDeclarativeAction &action = actions.at(ii);
- QDeclarativeMetaPropertyPrivate::write(action.property, action.toValue, QDeclarativeMetaPropertyPrivate::BypassInterceptor | QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ QDeclarativePropertyPrivate::write(action.property, action.toValue, QDeclarativePropertyPrivate::BypassInterceptor | QDeclarativePropertyPrivate::DontRemoveBinding);
}
}
};
@@ -1010,7 +1008,7 @@ void QDeclarativePropertyAction::transition(QDeclarativeStateActions &actions,
/*!
\qmlclass ParentAction QDeclarativeParentAction
- \since 4.7
+ \since 4.7
\inherits Animation
\brief The ParentAction element allows parent changes during animation.
@@ -1058,7 +1056,7 @@ void QDeclarativeParentActionPrivate::init()
{
Q_Q(QDeclarativeParentAction);
cpa = new QActionAnimation;
- QDeclarativeGraphics_setParent_noEvent(cpa, q);
+ QDeclarative_setParent_noEvent(cpa, q);
}
/*!
@@ -1133,7 +1131,7 @@ QAbstractAnimation *QDeclarativeParentAction::qtAnimation()
}
void QDeclarativeParentAction::transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction)
{
Q_D(QDeclarativeParentAction);
@@ -1214,7 +1212,7 @@ void QDeclarativeParentAction::transition(QDeclarativeStateActions &actions,
/*!
\qmlclass NumberAnimation QDeclarativeNumberAnimation
- \since 4.7
+ \since 4.7
\inherits PropertyAnimation
\brief The NumberAnimation element allows you to animate changes in properties of type qreal.
@@ -1278,7 +1276,7 @@ void QDeclarativeNumberAnimation::setTo(qreal t)
/*!
\qmlclass Vector3dAnimation QDeclarativeVector3dAnimation
- \since 4.7
+ \since 4.7
\inherits PropertyAnimation
\brief The Vector3dAnimation element allows you to animate changes in properties of type QVector3d.
*/
@@ -1337,6 +1335,7 @@ void QDeclarativeVector3dAnimation::setTo(QVector3D t)
/*!
\qmlclass RotationAnimation QDeclarativeRotationAnimation
+ \since 4.7
\inherits PropertyAnimation
\brief The RotationAnimation element allows you to animate rotations.
@@ -1511,12 +1510,18 @@ QDeclarativeAnimationGroup::QDeclarativeAnimationGroup(QObject *parent)
{
}
+QDeclarativeAnimationGroup::QDeclarativeAnimationGroup(QDeclarativeAnimationGroupPrivate &dd, QObject *parent)
+ : QDeclarativeAbstractAnimation(dd, parent)
+{
+}
+
void QDeclarativeAnimationGroupPrivate::append_animation(QDeclarativeListProperty<QDeclarativeAbstractAnimation> *list, QDeclarativeAbstractAnimation *a)
{
QDeclarativeAnimationGroup *q = qobject_cast<QDeclarativeAnimationGroup *>(list->object);
if (q) {
q->d_func()->animations.append(a);
a->setGroup(q);
+ q->d_func()->ag->addAnimation(a->qtAnimation());
}
}
@@ -1545,7 +1550,7 @@ QDeclarativeListProperty<QDeclarativeAbstractAnimation> QDeclarativeAnimationGro
/*!
\qmlclass SequentialAnimation QDeclarativeSequentialAnimation
- \since 4.7
+ \since 4.7
\inherits Animation
\brief The SequentialAnimation element allows you to run animations sequentially.
@@ -1582,7 +1587,7 @@ QAbstractAnimation *QDeclarativeSequentialAnimation::qtAnimation()
}
void QDeclarativeSequentialAnimation::transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction)
{
Q_D(QDeclarativeAnimationGroup);
@@ -1606,7 +1611,7 @@ void QDeclarativeSequentialAnimation::transition(QDeclarativeStateActions &actio
/*!
\qmlclass ParallelAnimation QDeclarativeParallelAnimation
- \since 4.7
+ \since 4.7
\inherits Animation
\brief The ParallelAnimation element allows you to run animations in parallel.
@@ -1647,7 +1652,7 @@ QAbstractAnimation *QDeclarativeParallelAnimation::qtAnimation()
}
void QDeclarativeParallelAnimation::transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction)
{
Q_D(QDeclarativeAnimationGroup);
@@ -1715,7 +1720,7 @@ void QDeclarativePropertyAnimationPrivate::convertVariant(QVariant &variant, int
/*!
\qmlclass PropertyAnimation QDeclarativePropertyAnimation
- \since 4.7
+ \since 4.7
\inherits Animation
\brief The PropertyAnimation element allows you to animate property changes.
@@ -1793,7 +1798,7 @@ void QDeclarativePropertyAnimationPrivate::init()
{
Q_Q(QDeclarativePropertyAnimation);
va = new QDeclarativeTimeLineValueAnimator;
- QDeclarativeGraphics_setParent_noEvent(va, q);
+ QDeclarative_setParent_noEvent(va, q);
}
/*!
@@ -2231,7 +2236,7 @@ struct PropertyUpdater : public QDeclarativeTimeLineValue
QDeclarativeAction &action = actions[ii];
if (v == 1.)
- QDeclarativeMetaPropertyPrivate::write(action.property, action.toValue, QDeclarativeMetaPropertyPrivate::BypassInterceptor | QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ QDeclarativePropertyPrivate::write(action.property, action.toValue, QDeclarativePropertyPrivate::BypassInterceptor | QDeclarativePropertyPrivate::DontRemoveBinding);
else {
if (!fromSourced && !fromDefined) {
action.fromValue = action.property.read();
@@ -2246,7 +2251,7 @@ struct PropertyUpdater : public QDeclarativeTimeLineValue
}
}
if (interpolator)
- QDeclarativeMetaPropertyPrivate::write(action.property, interpolator(action.fromValue.constData(), action.toValue.constData(), v), QDeclarativeMetaPropertyPrivate::BypassInterceptor | QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ QDeclarativePropertyPrivate::write(action.property, interpolator(action.fromValue.constData(), action.toValue.constData(), v), QDeclarativePropertyPrivate::BypassInterceptor | QDeclarativePropertyPrivate::DontRemoveBinding);
}
if (deleted)
return;
@@ -2257,7 +2262,7 @@ struct PropertyUpdater : public QDeclarativeTimeLineValue
};
void QDeclarativePropertyAnimation::transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction)
{
Q_D(QDeclarativePropertyAnimation);
@@ -2366,6 +2371,241 @@ void QDeclarativePropertyAnimation::transition(QDeclarativeStateActions &actions
}
}
+QDeclarativeParentAnimation::QDeclarativeParentAnimation(QObject *parent)
+ : QDeclarativeAnimationGroup(*(new QDeclarativeParentAnimationPrivate), parent)
+{
+ Q_D(QDeclarativeParentAnimation);
+ d->topLevelGroup = new QSequentialAnimationGroup;
+ QDeclarative_setParent_noEvent(d->topLevelGroup, this);
+
+ d->startAction = new QActionAnimation;
+ d->topLevelGroup->addAnimation(d->startAction);
+
+ d->ag = new QParallelAnimationGroup;
+ d->topLevelGroup->addAnimation(d->ag);
+
+ d->endAction = new QActionAnimation;
+ d->topLevelGroup->addAnimation(d->endAction);
+}
+
+QDeclarativeParentAnimation::~QDeclarativeParentAnimation()
+{
+}
+
+QDeclarativeItem *QDeclarativeParentAnimation::target() const
+{
+ Q_D(const QDeclarativeParentAnimation);
+ return d->target;
+}
+
+void QDeclarativeParentAnimation::setTarget(QDeclarativeItem *target)
+{
+ Q_D(QDeclarativeParentAnimation);
+ d->target = target;
+}
+
+QDeclarativeItem *QDeclarativeParentAnimation::newParent() const
+{
+ Q_D(const QDeclarativeParentAnimation);
+ return d->newParent;
+}
+
+void QDeclarativeParentAnimation::setNewParent(QDeclarativeItem *newParent)
+{
+ Q_D(QDeclarativeParentAnimation);
+ d->newParent = newParent;
+}
+
+QDeclarativeItem *QDeclarativeParentAnimation::via() const
+{
+ Q_D(const QDeclarativeParentAnimation);
+ return d->via;
+}
+
+void QDeclarativeParentAnimation::setVia(QDeclarativeItem *via)
+{
+ Q_D(QDeclarativeParentAnimation);
+ d->via = via;
+}
+
+//### mirrors same-named function in QDeclarativeItem
+QPointF QDeclarativeParentAnimationPrivate::computeTransformOrigin(QDeclarativeItem::TransformOrigin origin, qreal width, qreal height) const
+{
+ switch(origin) {
+ default:
+ case QDeclarativeItem::TopLeft:
+ return QPointF(0, 0);
+ case QDeclarativeItem::Top:
+ return QPointF(width / 2., 0);
+ case QDeclarativeItem::TopRight:
+ return QPointF(width, 0);
+ case QDeclarativeItem::Left:
+ return QPointF(0, height / 2.);
+ case QDeclarativeItem::Center:
+ return QPointF(width / 2., height / 2.);
+ case QDeclarativeItem::Right:
+ return QPointF(width, height / 2.);
+ case QDeclarativeItem::BottomLeft:
+ return QPointF(0, height);
+ case QDeclarativeItem::Bottom:
+ return QPointF(width / 2., height);
+ case QDeclarativeItem::BottomRight:
+ return QPointF(width, height);
+ }
+}
+
+void QDeclarativeParentAnimation::transition(QDeclarativeStateActions &actions,
+ QDeclarativeProperties &modified,
+ TransitionDirection direction)
+{
+ Q_D(QDeclarativeParentAnimation);
+
+ struct QDeclarativeParentActionData : public QAbstractAnimationAction
+ {
+ QDeclarativeParentActionData(): pc(0) {}
+ ~QDeclarativeParentActionData() { delete pc; }
+
+ QDeclarativeStateActions actions;
+ bool reverse;
+ QDeclarativeParentChange *pc;
+ virtual void doAction()
+ {
+ for (int ii = 0; ii < actions.count(); ++ii) {
+ const QDeclarativeAction &action = actions.at(ii);
+ if (reverse)
+ action.event->reverse();
+ else
+ action.event->execute();
+ }
+ }
+ };
+
+ QDeclarativeParentActionData *data = new QDeclarativeParentActionData;
+ QDeclarativeParentActionData *viaData = new QDeclarativeParentActionData;
+ for (int i = 0; i < actions.size(); ++i) {
+ QDeclarativeAction &action = actions[i];
+ if (action.event && action.event->typeName() == QLatin1String("ParentChange")
+ && (!d->target || static_cast<QDeclarativeParentChange*>(action.event)->object() == d->target)) {
+
+ QDeclarativeParentChange *pc = static_cast<QDeclarativeParentChange*>(action.event);
+ QDeclarativeAction myAction = action;
+ data->reverse = action.reverseEvent;
+ action.actionDone = true;
+ data->actions << myAction;
+
+ if (d->via) {
+ viaData->reverse = false;
+ QDeclarativeAction myAction;
+ QDeclarativeParentChange *vpc = new QDeclarativeParentChange;
+ vpc->setObject(pc->object());
+ vpc->setParent(d->via);
+ myAction.event = vpc;
+ viaData->pc = vpc;
+ viaData->actions << myAction;
+ QDeclarativeAction dummyAction;
+ QDeclarativeAction &xAction = pc->xIsSet() ? actions[++i] : dummyAction;
+ QDeclarativeAction &yAction = pc->yIsSet() ? actions[++i] : dummyAction;
+ QDeclarativeAction &sAction = pc->scaleIsSet() ? actions[++i] : dummyAction;
+ QDeclarativeAction &rAction = pc->rotationIsSet() ? actions[++i] : dummyAction;
+ bool forward = (direction == QDeclarativeAbstractAnimation::Forward);
+ QDeclarativeItem *target = pc->object();
+ QDeclarativeItem *targetParent = forward ? pc->parent() : pc->originalParent();
+
+ //### this mirrors the logic in QDeclarativeParentChange.
+ bool ok;
+ const QTransform &transform = targetParent->itemTransform(d->via, &ok);
+ if (transform.type() >= QTransform::TxShear || !ok) {
+ qmlInfo(this) << QDeclarativeParentAnimation::tr("Unable to preserve appearance under complex transform");
+ ok = false;
+ }
+
+ qreal scale = 1;
+ qreal rotation = 0;
+ if (ok && transform.type() != QTransform::TxRotate) {
+ if (transform.m11() == transform.m22())
+ scale = transform.m11();
+ else {
+ qmlInfo(this) << QDeclarativeParentAnimation::tr("Unable to preserve appearance under non-uniform scale");
+ ok = false;
+ }
+ } else if (ok && transform.type() == QTransform::TxRotate) {
+ if (transform.m11() == transform.m22())
+ scale = qSqrt(transform.m11()*transform.m11() + transform.m12()*transform.m12());
+ else {
+ qmlInfo(this) << QDeclarativeParentAnimation::tr("Unable to preserve appearance under non-uniform scale");
+ ok = false;
+ }
+
+ if (scale != 0)
+ rotation = atan2(transform.m12()/scale, transform.m11()/scale) * 180/M_PI;
+ else {
+ qmlInfo(this) << QDeclarativeParentAnimation::tr("Unable to preserve appearance under scale of 0");
+ ok = false;
+ }
+ }
+
+ const QPointF &point = transform.map(QPointF(xAction.toValue.toReal(),yAction.toValue.toReal()));
+ qreal x = point.x();
+ qreal y = point.y();
+ if (ok && target->transformOrigin() != QDeclarativeItem::TopLeft) {
+ qreal w = target->width();
+ qreal h = target->height();
+ if (pc->widthIsSet())
+ w = actions[++i].toValue.toReal();
+ if (pc->heightIsSet())
+ h = actions[++i].toValue.toReal();
+ const QPointF &transformOrigin
+ = d->computeTransformOrigin(target->transformOrigin(), w,h);
+ qreal tempxt = transformOrigin.x();
+ qreal tempyt = transformOrigin.y();
+ QTransform t;
+ t.translate(-tempxt, -tempyt);
+ t.rotate(rotation);
+ t.scale(scale, scale);
+ t.translate(tempxt, tempyt);
+ const QPointF &offset = t.map(QPointF(0,0));
+ x += offset.x();
+ y += offset.y();
+ }
+
+ if (ok) {
+ //qDebug() << x << y << rotation << scale;
+ xAction.toValue = x;
+ yAction.toValue = y;
+ sAction.toValue = sAction.toValue.toReal() * scale;
+ rAction.toValue = rAction.toValue.toReal() + rotation;
+ }
+ }
+ }
+ }
+
+ if (data->actions.count()) {
+ if (direction == QDeclarativeAbstractAnimation::Forward) {
+ d->startAction->setAnimAction(d->via ? viaData : data, QActionAnimation::DeleteWhenStopped);
+ d->endAction->setAnimAction(d->via ? data : 0, QActionAnimation::DeleteWhenStopped);
+ } else {
+ d->endAction->setAnimAction(d->via ? viaData : data, QActionAnimation::DeleteWhenStopped);
+ d->startAction->setAnimAction(d->via ? data : 0, QActionAnimation::DeleteWhenStopped);
+ }
+ } else {
+ delete data;
+ delete viaData;
+ }
+
+ //take care of any child animations
+ bool valid = d->defaultProperty.isValid();
+ for (int ii = 0; ii < d->animations.count(); ++ii) {
+ if (valid)
+ d->animations.at(ii)->setDefaultTarget(d->defaultProperty);
+ d->animations.at(ii)->transition(actions, modified, direction);
+ }
+
+}
+QAbstractAnimation *QDeclarativeParentAnimation::qtAnimation()
+{
+ Q_D(QDeclarativeParentAnimation);
+ return d->topLevelGroup;
+}
QT_END_NAMESPACE
diff --git a/src/declarative/util/qdeclarativeanimation_p.h b/src/declarative/util/qdeclarativeanimation_p.h
index 02dacb3..0f23f5c 100644
--- a/src/declarative/util/qdeclarativeanimation_p.h
+++ b/src/declarative/util/qdeclarativeanimation_p.h
@@ -95,7 +95,7 @@ public:
QDeclarativeAnimationGroup *group() const;
void setGroup(QDeclarativeAnimationGroup *);
- void setDefaultTarget(const QDeclarativeMetaProperty &);
+ void setDefaultTarget(const QDeclarativeProperty &);
void setDisableUserControl();
void classBegin();
@@ -123,7 +123,7 @@ protected:
public:
enum TransitionDirection { Forward, Backward };
virtual void transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction);
virtual QAbstractAnimation *qtAnimation() = 0;
@@ -131,7 +131,7 @@ private Q_SLOTS:
void timelineComplete();
private:
- virtual void setTarget(const QDeclarativeMetaProperty &);
+ virtual void setTarget(const QDeclarativeProperty &);
};
class QDeclarativePauseAnimationPrivate;
@@ -177,7 +177,7 @@ public:
protected:
virtual void transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction);
virtual QAbstractAnimation *qtAnimation();
};
@@ -221,7 +221,7 @@ Q_SIGNALS:
protected:
virtual void transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction);
virtual QAbstractAnimation *qtAnimation();
};
@@ -248,7 +248,7 @@ public:
protected:
virtual void transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction);
virtual QAbstractAnimation *qtAnimation();
};
@@ -300,7 +300,7 @@ public:
protected:
QDeclarativePropertyAnimation(QDeclarativePropertyAnimationPrivate &dd, QObject *parent);
virtual void transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction);
virtual QAbstractAnimation *qtAnimation();
@@ -413,6 +413,9 @@ public:
QDeclarativeListProperty<QDeclarativeAbstractAnimation> animations();
friend class QDeclarativeAbstractAnimation;
+
+protected:
+ QDeclarativeAnimationGroup(QDeclarativeAnimationGroupPrivate &dd, QObject *parent);
};
class QDeclarativeSequentialAnimation : public QDeclarativeAnimationGroup
@@ -426,7 +429,7 @@ public:
protected:
virtual void transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
TransitionDirection direction);
virtual QAbstractAnimation *qtAnimation();
};
@@ -442,7 +445,37 @@ public:
protected:
virtual void transition(QDeclarativeStateActions &actions,
- QDeclarativeMetaProperties &modified,
+ QDeclarativeProperties &modified,
+ TransitionDirection direction);
+ virtual QAbstractAnimation *qtAnimation();
+};
+
+class QDeclarativeParentAnimationPrivate;
+class QDeclarativeParentAnimation : public QDeclarativeAnimationGroup
+{
+ Q_OBJECT
+ Q_DECLARE_PRIVATE(QDeclarativeParentAnimation)
+
+ Q_PROPERTY(QDeclarativeItem *target READ target WRITE setTarget)
+ //Q_PROPERTY(QDeclarativeItem *newParent READ newParent WRITE setNewParent)
+ Q_PROPERTY(QDeclarativeItem *via READ via WRITE setVia)
+
+public:
+ QDeclarativeParentAnimation(QObject *parent=0);
+ virtual ~QDeclarativeParentAnimation();
+
+ QDeclarativeItem *target() const;
+ void setTarget(QDeclarativeItem *);
+
+ QDeclarativeItem *newParent() const;
+ void setNewParent(QDeclarativeItem *);
+
+ QDeclarativeItem *via() const;
+ void setVia(QDeclarativeItem *);
+
+protected:
+ virtual void transition(QDeclarativeStateActions &actions,
+ QDeclarativeProperties &modified,
TransitionDirection direction);
virtual QAbstractAnimation *qtAnimation();
};
@@ -461,6 +494,7 @@ QML_DECLARE_TYPE(QDeclarativeSequentialAnimation)
QML_DECLARE_TYPE(QDeclarativeParallelAnimation)
QML_DECLARE_TYPE(QDeclarativeVector3dAnimation)
QML_DECLARE_TYPE(QDeclarativeRotationAnimation)
+QML_DECLARE_TYPE(QDeclarativeParentAnimation)
QT_END_HEADER
diff --git a/src/declarative/util/qdeclarativeanimation_p_p.h b/src/declarative/util/qdeclarativeanimation_p_p.h
index 65c9807..e582066 100644
--- a/src/declarative/util/qdeclarativeanimation_p_p.h
+++ b/src/declarative/util/qdeclarativeanimation_p_p.h
@@ -59,6 +59,7 @@
#include "qdeclarativetimeline_p_p.h"
#include <qdeclarative.h>
+#include <qdeclarativeitem.h>
#include <qdeclarativecontext.h>
#include <QtCore/QPauseAnimation>
@@ -104,6 +105,12 @@ public:
: QAbstractAnimation(parent), animAction(action), policy(KeepWhenStopped), running(false) {}
~QActionAnimation() { if (policy == DeleteWhenStopped) { delete animAction; animAction = 0; } }
virtual int duration() const { return 0; }
+ void clearAnimAction()
+ {
+ if (policy == DeleteWhenStopped)
+ delete animAction;
+ animAction = 0;
+ }
void setAnimAction(QAbstractAnimationAction *action, DeletionPolicy p)
{
if (state() == Running)
@@ -226,11 +233,11 @@ public:
void commence();
- QDeclarativeMetaProperty defaultProperty;
+ QDeclarativeProperty defaultProperty;
QDeclarativeAnimationGroup *group;
- static QDeclarativeMetaProperty createProperty(QObject *obj, const QString &str, QObject *infoObj);
+ static QDeclarativeProperty createProperty(QObject *obj, const QString &str, QObject *infoObj);
};
class QDeclarativePauseAnimationPrivate : public QDeclarativeAbstractAnimationPrivate
@@ -311,8 +318,6 @@ public:
static void append_animation(QDeclarativeListProperty<QDeclarativeAbstractAnimation> *list, QDeclarativeAbstractAnimation *role);
static void clear_animation(QDeclarativeListProperty<QDeclarativeAbstractAnimation> *list);
- static void removeAt_animation(QDeclarativeListProperty<QDeclarativeAbstractAnimation> *list, int i);
- static void insert_animation(QDeclarativeListProperty<QDeclarativeAbstractAnimation> *list, int i, QDeclarativeAbstractAnimation *role);
QList<QDeclarativeAbstractAnimation *> animations;
QAnimationGroup *ag;
};
@@ -362,6 +367,25 @@ public:
QDeclarativeRotationAnimation::RotationDirection direction;
};
+class QDeclarativeParentAnimationPrivate : public QDeclarativeAnimationGroupPrivate
+{
+ Q_DECLARE_PUBLIC(QDeclarativeParentAnimation)
+public:
+ QDeclarativeParentAnimationPrivate()
+ : QDeclarativeAnimationGroupPrivate(), target(0), newParent(0),
+ via(0), topLevelGroup(0), startAction(0), endAction(0) {}
+
+ QDeclarativeItem *target;
+ QDeclarativeItem *newParent;
+ QDeclarativeItem *via;
+
+ QSequentialAnimationGroup *topLevelGroup;
+ QActionAnimation *startAction;
+ QActionAnimation *endAction;
+
+ QPointF computeTransformOrigin(QDeclarativeItem::TransformOrigin origin, qreal width, qreal height) const;
+};
+
QT_END_NAMESPACE
#endif // QDECLARATIVEANIMATION_P_H
diff --git a/src/declarative/util/qdeclarativebehavior.cpp b/src/declarative/util/qdeclarativebehavior.cpp
index b1f1677..5352341 100644
--- a/src/declarative/util/qdeclarativebehavior.cpp
+++ b/src/declarative/util/qdeclarativebehavior.cpp
@@ -46,7 +46,7 @@
#include <qdeclarativecontext.h>
#include <qdeclarativeinfo.h>
-#include <qdeclarativemetaproperty_p.h>
+#include <qdeclarativeproperty_p.h>
#include <QtCore/qparallelanimationgroup.h>
@@ -62,7 +62,7 @@ class QDeclarativeBehaviorPrivate : public QObjectPrivate
public:
QDeclarativeBehaviorPrivate() : animation(0), enabled(true) {}
- QDeclarativeMetaProperty property;
+ QDeclarativeProperty property;
QVariant currentValue;
QDeclarativeAbstractAnimation *animation;
bool enabled;
@@ -70,6 +70,7 @@ public:
/*!
\qmlclass Behavior QDeclarativeBehavior
+ \since 4.7
\brief The Behavior element allows you to specify a default animation for a property change.
Behaviors provide one way to specify \l{qdeclarativeanimation.html}{animations} in QML.
@@ -157,7 +158,7 @@ void QDeclarativeBehavior::write(const QVariant &value)
{
Q_D(QDeclarativeBehavior);
if (!d->animation || !d->enabled) {
- QDeclarativeMetaPropertyPrivate::write(d->property, value, QDeclarativeMetaPropertyPrivate::BypassInterceptor | QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ QDeclarativePropertyPrivate::write(d->property, value, QDeclarativePropertyPrivate::BypassInterceptor | QDeclarativePropertyPrivate::DontRemoveBinding);
return;
}
@@ -172,15 +173,15 @@ void QDeclarativeBehavior::write(const QVariant &value)
action.toValue = value;
actions << action;
- QList<QDeclarativeMetaProperty> after;
+ QList<QDeclarativeProperty> after;
if (d->animation)
d->animation->transition(actions, after, QDeclarativeAbstractAnimation::Forward);
d->animation->qtAnimation()->start();
if (!after.contains(d->property))
- QDeclarativeMetaPropertyPrivate::write(d->property, value, QDeclarativeMetaPropertyPrivate::BypassInterceptor | QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ QDeclarativePropertyPrivate::write(d->property, value, QDeclarativePropertyPrivate::BypassInterceptor | QDeclarativePropertyPrivate::DontRemoveBinding);
}
-void QDeclarativeBehavior::setTarget(const QDeclarativeMetaProperty &property)
+void QDeclarativeBehavior::setTarget(const QDeclarativeProperty &property)
{
Q_D(QDeclarativeBehavior);
d->property = property;
diff --git a/src/declarative/util/qdeclarativebehavior_p.h b/src/declarative/util/qdeclarativebehavior_p.h
index fbc19f8..a633b55 100644
--- a/src/declarative/util/qdeclarativebehavior_p.h
+++ b/src/declarative/util/qdeclarativebehavior_p.h
@@ -70,7 +70,7 @@ public:
QDeclarativeBehavior(QObject *parent=0);
~QDeclarativeBehavior();
- virtual void setTarget(const QDeclarativeMetaProperty &);
+ virtual void setTarget(const QDeclarativeProperty &);
virtual void write(const QVariant &value);
QDeclarativeAbstractAnimation *animation();
diff --git a/src/declarative/util/qdeclarativebind.cpp b/src/declarative/util/qdeclarativebind.cpp
index d75e98d..e95a03e 100644
--- a/src/declarative/util/qdeclarativebind.cpp
+++ b/src/declarative/util/qdeclarativebind.cpp
@@ -45,7 +45,7 @@
#include <qdeclarativeengine.h>
#include <qdeclarativecontext.h>
-#include <qdeclarativemetaproperty.h>
+#include <qdeclarativeproperty.h>
#include <QtCore/qfile.h>
#include <QtCore/qdebug.h>
@@ -196,7 +196,7 @@ void QDeclarativeBind::eval()
if (!d->obj || d->value.isNull || !d->when || !d->componentComplete)
return;
- QDeclarativeMetaProperty prop(d->obj, d->prop);
+ QDeclarativeProperty prop(d->obj, d->prop);
prop.write(d->value.value);
}
diff --git a/src/declarative/util/qdeclarativeconnection.cpp b/src/declarative/util/qdeclarativeconnection.cpp
deleted file mode 100644
index e9ae74b..0000000
--- a/src/declarative/util/qdeclarativeconnection.cpp
+++ /dev/null
@@ -1,287 +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$
-**
-****************************************************************************/
-
-#include "qdeclarativeconnection_p.h"
-
-#include <qdeclarativeexpression.h>
-#include <qdeclarativeboundsignal_p.h>
-#include <qdeclarativecontext.h>
-
-#include <QtCore/qdebug.h>
-#include <QtCore/qstringlist.h>
-
-#include <private/qobject_p.h>
-
-QT_BEGIN_NAMESPACE
-
-class QDeclarativeConnectionPrivate : public QObjectPrivate
-{
-public:
- QDeclarativeConnectionPrivate() : boundsignal(0), signalSender(0), scriptset(false), componentcomplete(false) {}
-
- QDeclarativeBoundSignal *boundsignal;
- QObject *signalSender;
- QDeclarativeScriptString script;
- bool scriptset;
- QString signal;
- bool componentcomplete;
-};
-
-/*!
- \qmlclass Connection QDeclarativeConnection
- \since 4.7
- \brief A Connection object describes generalized connections to signals.
-
- When connecting to signals in QML, the usual way is to create an
- "on<Signal>" handler that reacts when a signal is received, like this:
-
- \qml
- MouseArea {
- onClicked: { foo(x+123,y+456) }
- }
- \endqml
-
- However, in some cases, it is not possible to connect to a signal in this
- way. For example, JavaScript-in-HTML style signal properties do not allow:
-
- \list
- \i connecting to signals with the same name but different parameters
- \i conformance checking that parameters are correctly named
- \i multiple connections to the same signal
- \i connections outside the scope of the signal sender
- \i signals in classes with coincidentally-named on<Signal> properties
- \endlist
-
- When any of these are needed, the Connection object can be used instead.
-
- For example, the above code can be changed to use a Connection object,
- like this:
-
- \qml
- MouseArea {
- Connection {
- signal: "clicked(x,y)"
- script: { foo(x+123,y+456) }
- }
- }
- \endqml
-
- More generally, the Connection object can be a child of some other object than
- the sender of the signal:
-
- \qml
- MouseArea {
- id: mr
- }
- ...
- Connection {
- sender: mr
- signal: "clicked(x,y)"
- script: { foo(x+123,y+456) }
- }
- \endqml
-*/
-
-/*!
- \internal
- \class QDeclarativeConnection
- \brief The QDeclarativeConnection class describes generalized connections to signals.
-
-*/
-QDeclarativeConnection::QDeclarativeConnection(QObject *parent) :
- QObject(*(new QDeclarativeConnectionPrivate), parent)
-{
-}
-
-QDeclarativeConnection::~QDeclarativeConnection()
-{
- Q_D(QDeclarativeConnection);
- delete d->boundsignal;
-}
-
-/*!
- \qmlproperty Object Connection::sender
- This property holds the object that sends the signal.
-
- By default, the sender is assumed to be the parent of the Connection.
-*/
-QObject *QDeclarativeConnection::signalSender() const
-{
- Q_D(const QDeclarativeConnection);
- return d->signalSender ? d->signalSender : parent();
-}
-
-void QDeclarativeConnection::setSignalSender(QObject *obj)
-{
- Q_D(QDeclarativeConnection);
- if (d->signalSender == obj)
- return;
- disconnectIfValid();
- d->signalSender = obj;
- connectIfValid();
-}
-
-void QDeclarativeConnection::connectIfValid()
-{
- Q_D(QDeclarativeConnection);
- if (!d->componentcomplete)
- return;
- // boundsignal must not exist
- if ((d->signalSender || parent()) && !d->signal.isEmpty() && d->scriptset) {
- // create
- // XXX scope?
- int sigIdx = -1;
- int lparen = d->signal.indexOf(QLatin1Char('('));
- QList<QByteArray> sigparams;
- if (lparen >= 0 && d->signal.length() > lparen+2) {
- QStringList l = d->signal.mid(lparen+1,d->signal.length()-lparen-2).split(QLatin1Char(','));
- foreach (const QString &s, l) {
- sigparams.append(s.trimmed().toUtf8());
- }
- }
- QString signalname = d->signal.left(lparen);
- QObject *sender = d->signalSender ? d->signalSender : parent();
- const QMetaObject *mo = sender->metaObject();
- int methods = mo->methodCount();
- for (int ii = 0; ii < methods; ++ii) {
- QMetaMethod method = mo->method(ii);
- QString methodName = QString::fromUtf8(method.signature());
- int idx = methodName.indexOf(QLatin1Char('('));
- methodName = methodName.left(idx);
- if (methodName == signalname && (lparen<0 || method.parameterNames() == sigparams)) {
- sigIdx = ii;
- break;
- }
- }
- if (sigIdx < 0) {
- // Cannot usefully warn, since could be in middle of
- // changing sender and signal.
- // XXX need state change transactions to do better
- return;
- }
-
- d->boundsignal = new QDeclarativeBoundSignal(qmlContext(this), d->script.script(), sender, mo->method(sigIdx), this);
- }
-}
-
-void QDeclarativeConnection::disconnectIfValid()
-{
- Q_D(QDeclarativeConnection);
- if (!d->componentcomplete)
- return;
- if ((d->signalSender || parent()) && !d->signal.isEmpty() && d->scriptset) {
- // boundsignal must exist
- // destroy
- delete d->boundsignal;
- d->boundsignal = 0;
- }
-}
-
-void QDeclarativeConnection::componentComplete()
-{
- Q_D(QDeclarativeConnection);
- d->componentcomplete=true;
- connectIfValid();
-}
-
-
-/*!
- \qmlproperty script Connection::script
- This property holds the JavaScript executed whenever the signal is sent.
-*/
-QDeclarativeScriptString QDeclarativeConnection::script() const
-{
- Q_D(const QDeclarativeConnection);
- return d->script;
-}
-
-void QDeclarativeConnection::setScript(const QDeclarativeScriptString& script)
-{
- Q_D(QDeclarativeConnection);
- if ((d->signalSender || parent()) && !d->signal.isEmpty()) {
- if (!d->scriptset) {
- // mustn't exist - create
- d->scriptset = true;
- d->script = script;
- connectIfValid();
- } else {
- // must exist - update
- d->script = script;
- d->boundsignal->expression()->setExpression(script.script());
- }
- } else {
- d->scriptset = true;
- d->script = script;
- }
-}
-
-/*!
- \qmlproperty string Connection::signal
- This property holds the signal from the sender to which the script is attached.
-
- The signal's formal parameter names must be given in parentheses:
-
- \qml
-Connection {
- signal: "clicked(x,y)"
- script: { ... }
-}
- \endqml
-*/
-QString QDeclarativeConnection::signal() const
-{
- Q_D(const QDeclarativeConnection);
- return d->signal;
-}
-
-void QDeclarativeConnection::setSignal(const QString& sig)
-{
- Q_D(QDeclarativeConnection);
- if (d->signal == sig)
- return;
- disconnectIfValid();
- d->signal = sig;
- connectIfValid();
-}
-
-
-
-QT_END_NAMESPACE
diff --git a/src/declarative/util/qdeclarativeconnections.cpp b/src/declarative/util/qdeclarativeconnections.cpp
new file mode 100644
index 0000000..0b9e3ab
--- /dev/null
+++ b/src/declarative/util/qdeclarativeconnections.cpp
@@ -0,0 +1,245 @@
+/****************************************************************************
+**
+** 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$
+**
+****************************************************************************/
+
+#include "qdeclarativeconnections_p.h"
+
+#include <qdeclarativeexpression.h>
+#include <qdeclarativeproperty_p.h>
+#include <qdeclarativeboundsignal_p.h>
+#include <qdeclarativecontext.h>
+#include <qdeclarativeinfo.h>
+
+#include <QtCore/qdebug.h>
+#include <QtCore/qstringlist.h>
+
+#include <private/qobject_p.h>
+
+QT_BEGIN_NAMESPACE
+
+class QDeclarativeConnectionsPrivate : public QObjectPrivate
+{
+public:
+ QDeclarativeConnectionsPrivate() : target(0), componentcomplete(false) {}
+
+ QList<QDeclarativeBoundSignal*> boundsignals;
+ QObject *target;
+
+ bool componentcomplete;
+
+ QByteArray data;
+};
+
+/*!
+ \qmlclass Connections QDeclarativeConnections
+ \since 4.7
+ \brief A Connections object describes generalized connections to signals.
+
+ When connecting to signals in QML, the usual way is to create an
+ "on<Signal>" handler that reacts when a signal is received, like this:
+
+ \qml
+ MouseArea {
+ onClicked: { foo(...) }
+ }
+ \endqml
+
+ However, in some cases, it is not possible to connect to a signal in this
+ way, such as:
+
+ \list
+ \i multiple connections to the same signal
+ \i connections outside the scope of the signal sender
+ \i connections to targets not defined in QML
+ \endlist
+
+ When any of these are needed, the Connections object can be used instead.
+
+ For example, the above code can be changed to use a Connections object,
+ like this:
+
+ \qml
+ MouseArea {
+ Connections {
+ onClicked: foo(...)
+ }
+ }
+ \endqml
+
+ More generally, the Connections object can be a child of some other object than
+ the sender of the signal:
+
+ \qml
+ MouseArea {
+ id: area
+ }
+ ...
+ Connections {
+ target: area
+ onClicked: foo(...)
+ }
+ \endqml
+*/
+
+/*!
+ \internal
+ \class QDeclarativeConnections
+ \brief The QDeclarativeConnections class describes generalized connections to signals.
+
+*/
+QDeclarativeConnections::QDeclarativeConnections(QObject *parent) :
+ QObject(*(new QDeclarativeConnectionsPrivate), parent)
+{
+}
+
+QDeclarativeConnections::~QDeclarativeConnections()
+{
+}
+
+/*!
+ \qmlproperty Object Connections::target
+ This property holds the object that sends the signal.
+
+ By default, the target is assumed to be the parent of the Connections.
+*/
+QObject *QDeclarativeConnections::target() const
+{
+ Q_D(const QDeclarativeConnections);
+ return d->target ? d->target : parent();
+}
+
+void QDeclarativeConnections::setTarget(QObject *obj)
+{
+ Q_D(QDeclarativeConnections);
+ if (d->target == obj)
+ return;
+ foreach (QDeclarativeBoundSignal *s, d->boundsignals)
+ delete s;
+ d->boundsignals.clear();
+ d->target = obj;
+ connectSignals();
+ emit targetChanged();
+}
+
+
+QByteArray
+QDeclarativeConnectionsParser::compile(const QList<QDeclarativeCustomParserProperty> &props)
+{
+ QByteArray rv;
+ QDataStream ds(&rv, QIODevice::WriteOnly);
+
+ for(int ii = 0; ii < props.count(); ++ii)
+ {
+ QString propName = QString::fromUtf8(props.at(ii).name());
+ if (!propName.startsWith(QLatin1String("on")) || !propName.at(2).isUpper()) {
+ error(props.at(ii), QDeclarativeConnections::tr("Cannot assign to non-existent property \"%1\"").arg(propName));
+ return QByteArray();
+ }
+
+ QList<QVariant> values = props.at(ii).assignedValues();
+
+ for (int i = 0; i < values.count(); ++i) {
+ const QVariant &value = values.at(i);
+
+ if (value.userType() == qMetaTypeId<QDeclarativeCustomParserNode>()) {
+ error(props.at(ii), QDeclarativeConnections::tr("Connections: nested objects not allowed"));
+ return QByteArray();
+ } else if (value.userType() == qMetaTypeId<QDeclarativeCustomParserProperty>()) {
+ error(props.at(ii), QDeclarativeConnections::tr("Connections: syntax error"));
+ return QByteArray();
+ } else {
+ QDeclarativeParser::Variant v = qvariant_cast<QDeclarativeParser::Variant>(value);
+ if (v.isScript()) {
+ ds << propName;
+ ds << v.asScript();
+ } else {
+ error(props.at(ii), QDeclarativeConnections::tr("Connections: script expected"));
+ return QByteArray();
+ }
+ }
+ }
+ }
+
+ return rv;
+}
+
+void QDeclarativeConnectionsParser::setCustomData(QObject *object,
+ const QByteArray &data)
+{
+ QDeclarativeConnectionsPrivate *p =
+ static_cast<QDeclarativeConnectionsPrivate *>(QObjectPrivate::get(object));
+ p->data = data;
+}
+
+
+void QDeclarativeConnections::connectSignals()
+{
+ Q_D(QDeclarativeConnections);
+ if (!d->componentcomplete)
+ return;
+
+ QDataStream ds(d->data);
+ while (!ds.atEnd()) {
+ QString propName;
+ ds >> propName;
+ QString script;
+ ds >> script;
+ QDeclarativeProperty prop(target(), propName);
+ if (!prop.isValid()) {
+ qmlInfo(this) << tr("Cannot assign to non-existent property \"%1\"").arg(propName);
+ } else if (prop.type() & QDeclarativeProperty::SignalProperty) {
+ QDeclarativeBoundSignal *signal =
+ new QDeclarativeBoundSignal(target(), prop.method(), this);
+ signal->setExpression(new QDeclarativeExpression(qmlContext(this), script, 0));
+ d->boundsignals += signal;
+ } else {
+ qmlInfo(this) << tr("Cannot assign to non-existent property \"%1\"").arg(propName);
+ }
+ }
+}
+
+void QDeclarativeConnections::componentComplete()
+{
+ Q_D(QDeclarativeConnections);
+ d->componentcomplete=true;
+ connectSignals();
+}
+
+QT_END_NAMESPACE
diff --git a/src/declarative/util/qdeclarativeconnection_p.h b/src/declarative/util/qdeclarativeconnections_p.h
index ae2efe9..3eacf12 100644
--- a/src/declarative/util/qdeclarativeconnection_p.h
+++ b/src/declarative/util/qdeclarativeconnections_p.h
@@ -39,11 +39,12 @@
**
****************************************************************************/
-#ifndef QDECLARATIVECONNECTION_H
-#define QDECLARATIVECONNECTION_H
+#ifndef QDECLARATIVECONNECTIONS_H
+#define QDECLARATIVECONNECTIONS_H
#include <qdeclarative.h>
#include <qdeclarativescriptstring.h>
+#include <private/qdeclarativecustomparser_p.h>
#include <QtCore/qobject.h>
#include <QtCore/qstring.h>
@@ -56,37 +57,41 @@ QT_MODULE(Declarative)
class QDeclarativeBoundSignal;
class QDeclarativeContext;
-class QDeclarativeConnectionPrivate;
-class Q_DECLARATIVE_EXPORT QDeclarativeConnection : public QObject, public QDeclarativeParserStatus
+class QDeclarativeConnectionsPrivate;
+class Q_DECLARATIVE_EXPORT QDeclarativeConnections : public QObject, public QDeclarativeParserStatus
{
Q_OBJECT
- Q_DECLARE_PRIVATE(QDeclarativeConnection)
+ Q_DECLARE_PRIVATE(QDeclarativeConnections)
Q_INTERFACES(QDeclarativeParserStatus)
- Q_PROPERTY(QObject *sender READ signalSender WRITE setSignalSender)
- Q_PROPERTY(QDeclarativeScriptString script READ script WRITE setScript)
- Q_PROPERTY(QString signal READ signal WRITE setSignal)
+ Q_PROPERTY(QObject *target READ target WRITE setTarget NOTIFY targetChanged)
public:
- QDeclarativeConnection(QObject *parent=0);
- ~QDeclarativeConnection();
+ QDeclarativeConnections(QObject *parent=0);
+ ~QDeclarativeConnections();
- QObject *signalSender() const;
- void setSignalSender(QObject *);
- QDeclarativeScriptString script() const;
- void setScript(const QDeclarativeScriptString&);
- QString signal() const;
- void setSignal(const QString&);
+ QObject *target() const;
+ void setTarget(QObject *);
+
+Q_SIGNALS:
+ void targetChanged();
private:
- void disconnectIfValid();
- void connectIfValid();
+ void connectSignals();
void componentComplete();
};
+class QDeclarativeConnectionsParser : public QDeclarativeCustomParser
+{
+public:
+ virtual QByteArray compile(const QList<QDeclarativeCustomParserProperty> &);
+ virtual void setCustomData(QObject *, const QByteArray &);
+};
+
+
QT_END_NAMESPACE
-QML_DECLARE_TYPE(QDeclarativeConnection)
+QML_DECLARE_TYPE(QDeclarativeConnections)
QT_END_HEADER
diff --git a/src/declarative/util/qdeclarativeeasefollow.cpp b/src/declarative/util/qdeclarativeeasefollow.cpp
index 0430a0b..3fa9866 100644
--- a/src/declarative/util/qdeclarativeeasefollow.cpp
+++ b/src/declarative/util/qdeclarativeeasefollow.cpp
@@ -43,7 +43,7 @@
#include "qdeclarativeanimation_p_p.h"
-#include <qdeclarativemetaproperty.h>
+#include <qdeclarativeproperty.h>
#include <QtCore/qdebug.h>
@@ -77,7 +77,7 @@ public:
qreal trackVelocity;
- QDeclarativeMetaProperty target;
+ QDeclarativeProperty target;
int clockOffset;
int lastTick;
@@ -251,6 +251,7 @@ void QDeclarativeEaseFollowPrivate::tick(int t)
/*!
\qmlclass EaseFollow QDeclarativeEaseFollow
+ \since 4.7
\brief The EaseFollow element allows a property to smoothly track a value.
The EaseFollow smoothly animates a property's value to a set target value
@@ -500,7 +501,7 @@ void QDeclarativeEaseFollow::setEnabled(bool enabled)
emit enabledChanged();
}
-void QDeclarativeEaseFollow::setTarget(const QDeclarativeMetaProperty &t)
+void QDeclarativeEaseFollow::setTarget(const QDeclarativeProperty &t)
{
Q_D(QDeclarativeEaseFollow);
d->target = t;
diff --git a/src/declarative/util/qdeclarativeeasefollow_p.h b/src/declarative/util/qdeclarativeeasefollow_p.h
index 6d14eb5..83d1eff 100644
--- a/src/declarative/util/qdeclarativeeasefollow_p.h
+++ b/src/declarative/util/qdeclarativeeasefollow_p.h
@@ -53,7 +53,7 @@ QT_BEGIN_NAMESPACE
QT_MODULE(Declarative)
-class QDeclarativeMetaProperty;
+class QDeclarativeProperty;
class QDeclarativeEaseFollowPrivate;
class Q_DECLARATIVE_EXPORT QDeclarativeEaseFollow : public QObject,
public QDeclarativePropertyValueSource
@@ -94,7 +94,7 @@ public:
qreal maximumEasingTime() const;
void setMaximumEasingTime(qreal);
- virtual void setTarget(const QDeclarativeMetaProperty &);
+ virtual void setTarget(const QDeclarativeProperty &);
Q_SIGNALS:
void sourceChanged();
diff --git a/src/declarative/util/qdeclarativefontloader.cpp b/src/declarative/util/qdeclarativefontloader.cpp
index ac30384..4d12ae1 100644
--- a/src/declarative/util/qdeclarativefontloader.cpp
+++ b/src/declarative/util/qdeclarativefontloader.cpp
@@ -75,6 +75,7 @@ public:
/*!
\qmlclass FontLoader QDeclarativeFontLoader
+ \since 4.7
\ingroup group_utility
\brief This item allows using fonts by name or url.
diff --git a/src/declarative/util/qdeclarativelistmodel.cpp b/src/declarative/util/qdeclarativelistmodel.cpp
index e78e0e1..e3f26d7 100644
--- a/src/declarative/util/qdeclarativelistmodel.cpp
+++ b/src/declarative/util/qdeclarativelistmodel.cpp
@@ -70,6 +70,7 @@ static void dump(ModelNode *node, int ind);
/*!
\qmlclass ListModel QDeclarativeListModel
+ \since 4.7
\brief The ListModel element defines a free-form list data source.
The ListModel is a simple hierarchy of elements containing data roles. The contents can
@@ -936,6 +937,7 @@ bool QDeclarativeListModelParser::definesEmptyList(const QString &s)
/*!
\qmlclass ListElement
+ \since 4.7
\brief The ListElement element defines a data item in a ListModel.
\sa ListModel
diff --git a/src/declarative/util/qdeclarativelistmodel_p.h b/src/declarative/util/qdeclarativelistmodel_p.h
index 251a31f..8eb6583 100644
--- a/src/declarative/util/qdeclarativelistmodel_p.h
+++ b/src/declarative/util/qdeclarativelistmodel_p.h
@@ -50,7 +50,7 @@
#include <QtCore/QHash>
#include <QtCore/QList>
#include <QtCore/QVariant>
-#include "../3rdparty/qlistmodelinterface_p.h"
+#include <private/qlistmodelinterface_p.h>
#include <QtScript/qscriptvalue.h>
QT_BEGIN_HEADER
diff --git a/src/declarative/util/qdeclarativepackage.cpp b/src/declarative/util/qdeclarativepackage.cpp
index 34ae466..d144777 100644
--- a/src/declarative/util/qdeclarativepackage.cpp
+++ b/src/declarative/util/qdeclarativepackage.cpp
@@ -42,7 +42,7 @@
#include "qdeclarativepackage_p.h"
#include <private/qobject_p.h>
-#include "private/qdeclarativeguard_p.h"
+#include <private/qdeclarativeguard_p.h>
QT_BEGIN_NAMESPACE
diff --git a/src/declarative/util/qdeclarativepropertychanges.cpp b/src/declarative/util/qdeclarativepropertychanges.cpp
index 454fb06..9c2b1e6 100644
--- a/src/declarative/util/qdeclarativepropertychanges.cpp
+++ b/src/declarative/util/qdeclarativepropertychanges.cpp
@@ -50,7 +50,7 @@
#include <qdeclarativebinding_p.h>
#include <qdeclarativecontext.h>
#include <qdeclarativeguard_p.h>
-#include <qdeclarativemetaproperty_p.h>
+#include <qdeclarativeproperty_p.h>
#include <QtCore/qdebug.h>
@@ -153,19 +153,19 @@ public:
virtual QString typeName() const { return QLatin1String("ReplaceSignalHandler"); }
- QDeclarativeMetaProperty property;
+ QDeclarativeProperty property;
QDeclarativeExpression *expression;
QDeclarativeExpression *reverseExpression;
QDeclarativeExpression *rewindExpression;
QDeclarativeGuard<QDeclarativeExpression> ownedExpression;
virtual void execute() {
- ownedExpression = QDeclarativeMetaPropertyPrivate::setSignalExpression(property, expression);
+ ownedExpression = QDeclarativePropertyPrivate::setSignalExpression(property, expression);
}
virtual bool isReversable() { return true; }
virtual void reverse() {
- ownedExpression = QDeclarativeMetaPropertyPrivate::setSignalExpression(property, reverseExpression);
+ ownedExpression = QDeclarativePropertyPrivate::setSignalExpression(property, reverseExpression);
}
virtual void saveOriginals() {
@@ -174,10 +174,10 @@ public:
}
virtual void rewind() {
- ownedExpression = QDeclarativeMetaPropertyPrivate::setSignalExpression(property, rewindExpression);
+ ownedExpression = QDeclarativePropertyPrivate::setSignalExpression(property, rewindExpression);
}
virtual void saveCurrentValues() {
- rewindExpression = QDeclarativeMetaPropertyPrivate::signalExpression(property);
+ rewindExpression = QDeclarativePropertyPrivate::signalExpression(property);
}
virtual bool override(QDeclarativeActionEvent*other) {
@@ -212,7 +212,7 @@ public:
QList<QPair<QByteArray, QDeclarativeExpression *> > expressions;
QList<QDeclarativeReplaceSignalHandler*> signalReplacements;
- QDeclarativeMetaProperty property(const QByteArray &);
+ QDeclarativeProperty property(const QByteArray &);
};
void
@@ -296,8 +296,8 @@ void QDeclarativePropertyChangesPrivate::decode()
ds >> isScript;
ds >> data;
- QDeclarativeMetaProperty prop = property(name); //### better way to check for signal property?
- if (prop.type() & QDeclarativeMetaProperty::SignalProperty) {
+ QDeclarativeProperty prop = property(name); //### better way to check for signal property?
+ if (prop.type() & QDeclarativeProperty::SignalProperty) {
QDeclarativeExpression *expression = new QDeclarativeExpression(qmlContext(q), data.toString(), object);
QDeclarativeReplaceSignalHandler *handler = new QDeclarativeReplaceSignalHandler;
handler->property = prop;
@@ -371,17 +371,17 @@ void QDeclarativePropertyChanges::setRestoreEntryValues(bool v)
d->restore = v;
}
-QDeclarativeMetaProperty
+QDeclarativeProperty
QDeclarativePropertyChangesPrivate::property(const QByteArray &property)
{
Q_Q(QDeclarativePropertyChanges);
- QDeclarativeMetaProperty prop(object, QString::fromUtf8(property));
+ QDeclarativeProperty prop(object, QString::fromUtf8(property));
if (!prop.isValid()) {
qmlInfo(q) << QDeclarativePropertyChanges::tr("Cannot assign to non-existent property \"%1\"").arg(QString::fromUtf8(property));
- return QDeclarativeMetaProperty();
- } else if (!(prop.type() & QDeclarativeMetaProperty::SignalProperty) && !prop.isWritable()) {
+ return QDeclarativeProperty();
+ } else if (!(prop.type() & QDeclarativeProperty::SignalProperty) && !prop.isWritable()) {
qmlInfo(q) << QDeclarativePropertyChanges::tr("Cannot assign to read-only property \"%1\"").arg(QString::fromUtf8(property));
- return QDeclarativeMetaProperty();
+ return QDeclarativeProperty();
}
return prop;
}
@@ -426,7 +426,7 @@ QDeclarativePropertyChanges::ActionList QDeclarativePropertyChanges::actions()
for (int ii = 0; ii < d->expressions.count(); ++ii) {
QByteArray property = d->expressions.at(ii).first;
- QDeclarativeMetaProperty prop = d->property(property);
+ QDeclarativeProperty prop = d->property(property);
if (prop.isValid()) {
QDeclarativeAction a;
diff --git a/src/declarative/util/qdeclarativespringfollow.cpp b/src/declarative/util/qdeclarativespringfollow.cpp
index b26a7e2..6205ab9 100644
--- a/src/declarative/util/qdeclarativespringfollow.cpp
+++ b/src/declarative/util/qdeclarativespringfollow.cpp
@@ -63,7 +63,7 @@ public:
, mass(1.0), spring(0.), damping(0.), velocity(0), epsilon(0.01)
, modulus(0.0), useMass(false), haveModulus(false), enabled(true), mode(Track), clock(this) {}
- QDeclarativeMetaProperty property;
+ QDeclarativeProperty property;
qreal currentValue;
qreal sourceValue;
qreal maxVelocity;
@@ -213,6 +213,7 @@ void QDeclarativeSpringFollowPrivate::stop()
/*!
\qmlclass SpringFollow QDeclarativeSpringFollow
+ \since 4.7
\brief The SpringFollow element allows a property to track a value.
In example below, \e rect2 will follow \e rect1 moving with a velocity of up to 200:
@@ -254,7 +255,7 @@ QDeclarativeSpringFollow::~QDeclarativeSpringFollow()
{
}
-void QDeclarativeSpringFollow::setTarget(const QDeclarativeMetaProperty &property)
+void QDeclarativeSpringFollow::setTarget(const QDeclarativeProperty &property)
{
Q_D(QDeclarativeSpringFollow);
d->property = property;
diff --git a/src/declarative/util/qdeclarativespringfollow_p.h b/src/declarative/util/qdeclarativespringfollow_p.h
index 63d38a4..2ac0d82 100644
--- a/src/declarative/util/qdeclarativespringfollow_p.h
+++ b/src/declarative/util/qdeclarativespringfollow_p.h
@@ -74,7 +74,7 @@ public:
QDeclarativeSpringFollow(QObject *parent=0);
~QDeclarativeSpringFollow();
- virtual void setTarget(const QDeclarativeMetaProperty &);
+ virtual void setTarget(const QDeclarativeProperty &);
qreal sourceValue() const;
void setSourceValue(qreal value);
diff --git a/src/declarative/util/qdeclarativestate.cpp b/src/declarative/util/qdeclarativestate.cpp
index 3b06e33..1d70d33 100644
--- a/src/declarative/util/qdeclarativestate.cpp
+++ b/src/declarative/util/qdeclarativestate.cpp
@@ -334,7 +334,7 @@ void QDeclarativeState::cancel()
void QDeclarativeAction::deleteFromBinding()
{
if (fromBinding) {
- QDeclarativeMetaPropertyPrivate::setBinding(property, 0);
+ QDeclarativePropertyPrivate::setBinding(property, 0);
fromBinding->destroy();
fromBinding = 0;
}
@@ -388,7 +388,7 @@ void QDeclarativeState::apply(QDeclarativeStateGroup *group, QDeclarativeTransit
else if (action.event->isRewindable())
action.event->saveCurrentValues();
} else {
- action.fromBinding = QDeclarativeMetaPropertyPrivate::binding(action.property);
+ action.fromBinding = QDeclarativePropertyPrivate::binding(action.property);
for (jj = 0; jj < d->revertList.count(); ++jj) {
if (d->revertList.at(jj).property == action.property) {
@@ -437,7 +437,7 @@ void QDeclarativeState::apply(QDeclarativeStateGroup *group, QDeclarativeTransit
if (!found) {
QVariant cur = d->revertList.at(ii).property.read();
QDeclarativeAbstractBinding *delBinding =
- QDeclarativeMetaPropertyPrivate::setBinding(d->revertList.at(ii).property, 0);
+ QDeclarativePropertyPrivate::setBinding(d->revertList.at(ii).property, 0);
if (delBinding)
delBinding->destroy();
diff --git a/src/declarative/util/qdeclarativestate_p.h b/src/declarative/util/qdeclarativestate_p.h
index 4a62481..0c6e7a3 100644
--- a/src/declarative/util/qdeclarativestate_p.h
+++ b/src/declarative/util/qdeclarativestate_p.h
@@ -43,7 +43,7 @@
#define QDECLARATIVESTATE_H
#include <qdeclarative.h>
-#include <qdeclarativemetaproperty.h>
+#include <qdeclarativeproperty.h>
#include <QtCore/qobject.h>
QT_BEGIN_HEADER
@@ -53,7 +53,9 @@ QT_BEGIN_NAMESPACE
QT_MODULE(Declarative)
class QDeclarativeActionEvent;
+class QDeclarativeAbstractBinding;
class QDeclarativeBinding;
+class QDeclarativeExpression;
class Q_DECLARATIVE_EXPORT QDeclarativeAction
{
public:
@@ -65,7 +67,7 @@ public:
bool reverseEvent:1;
bool deletableToBinding:1;
- QDeclarativeMetaProperty property;
+ QDeclarativeProperty property;
QVariant fromValue;
QVariant toValue;
diff --git a/src/declarative/util/qdeclarativestate_p_p.h b/src/declarative/util/qdeclarativestate_p_p.h
index 6b32f04..6f52219 100644
--- a/src/declarative/util/qdeclarativestate_p_p.h
+++ b/src/declarative/util/qdeclarativestate_p_p.h
@@ -58,7 +58,7 @@
#include "qdeclarativeanimation_p_p.h"
#include "qdeclarativetransitionmanager_p_p.h"
-#include <qdeclarativemetaproperty_p.h>
+#include <qdeclarativeproperty_p.h>
#include <qdeclarativeguard_p.h>
#include <private/qobject_p.h>
@@ -77,7 +77,7 @@ public:
event = a.event;
if (state == StartState) {
value = a.fromValue;
- binding = QDeclarativeMetaPropertyPrivate::binding(property);
+ binding = QDeclarativePropertyPrivate::binding(property);
reverseEvent = true;
} else {
value = a.toValue;
@@ -86,7 +86,7 @@ public:
}
}
- QDeclarativeMetaProperty property;
+ QDeclarativeProperty property;
QVariant value;
QDeclarativeAbstractBinding *binding;
QObject *specifiedObject;
@@ -139,7 +139,7 @@ public:
QDeclarativeTransitionManager transitionManager;
SimpleActionList revertList;
- QList<QDeclarativeMetaProperty> reverting;
+ QList<QDeclarativeProperty> reverting;
QString extends;
mutable bool inState;
QDeclarativeStateGroup *group;
diff --git a/src/declarative/util/qdeclarativestategroup.cpp b/src/declarative/util/qdeclarativestategroup.cpp
index 1a7c256..083e87d 100644
--- a/src/declarative/util/qdeclarativestategroup.cpp
+++ b/src/declarative/util/qdeclarativestategroup.cpp
@@ -84,6 +84,7 @@ public:
/*!
\qmlclass StateGroup QDeclarativeStateGroup
+ \since 4.7
\brief The StateGroup element provides state support for non-Item elements.
Item (and all dervied elements) provides built in support for states and transitions
@@ -406,7 +407,7 @@ void QDeclarativeStateGroupPrivate::setCurrentStateInternal(const QString &state
}
if (oldState == 0 || newState == 0) {
- if (!nullState) { nullState = new QDeclarativeState; QDeclarativeGraphics_setParent_noEvent(nullState, q); }
+ if (!nullState) { nullState = new QDeclarativeState; QDeclarative_setParent_noEvent(nullState, q); }
if (!oldState) oldState = nullState;
if (!newState) newState = nullState;
}
diff --git a/src/declarative/util/qdeclarativestateoperations.cpp b/src/declarative/util/qdeclarativestateoperations.cpp
index 98edf85..cea9ad7 100644
--- a/src/declarative/util/qdeclarativestateoperations.cpp
+++ b/src/declarative/util/qdeclarativestateoperations.cpp
@@ -48,6 +48,7 @@
#include <qdeclarativeanchors_p_p.h>
#include <qdeclarativeitem_p.h>
#include <qdeclarativeguard_p.h>
+#include <qdeclarativenullablevalue_p_p.h>
#include <QtCore/qdebug.h>
#include <QtGui/qgraphicsitem.h>
@@ -62,7 +63,7 @@ class QDeclarativeParentChangePrivate : public QObjectPrivate
Q_DECLARE_PUBLIC(QDeclarativeParentChange)
public:
QDeclarativeParentChangePrivate() : target(0), parent(0), origParent(0), origStackBefore(0),
- rewindParent(0), rewindStackBefore(0) {}
+ rewindParent(0), rewindStackBefore(0) {}
QDeclarativeItem *target;
QDeclarativeItem *parent;
@@ -71,6 +72,13 @@ public:
QDeclarativeItem *rewindParent;
QDeclarativeItem *rewindStackBefore;
+ QDeclarativeNullableValue<qreal> x;
+ QDeclarativeNullableValue<qreal> y;
+ QDeclarativeNullableValue<qreal> width;
+ QDeclarativeNullableValue<qreal> height;
+ QDeclarativeNullableValue<qreal> scale;
+ QDeclarativeNullableValue<qreal> rotation;
+
void doChange(QDeclarativeItem *targetParent, QDeclarativeItem *stackBefore = 0);
};
@@ -173,6 +181,120 @@ QDeclarativeParentChange::~QDeclarativeParentChange()
{
}
+qreal QDeclarativeParentChange::x() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->x.isNull ? qreal(0.) : d->x.value;
+}
+
+void QDeclarativeParentChange::setX(qreal x)
+{
+ Q_D(QDeclarativeParentChange);
+ d->x = x;
+}
+
+bool QDeclarativeParentChange::xIsSet() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->x.isValid();
+}
+
+qreal QDeclarativeParentChange::y() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->y.isNull ? qreal(0.) : d->y.value;
+}
+
+void QDeclarativeParentChange::setY(qreal y)
+{
+ Q_D(QDeclarativeParentChange);
+ d->y = y;
+}
+
+bool QDeclarativeParentChange::yIsSet() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->y.isValid();
+}
+
+qreal QDeclarativeParentChange::width() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->width.isNull ? qreal(0.) : d->width.value;
+}
+
+void QDeclarativeParentChange::setWidth(qreal width)
+{
+ Q_D(QDeclarativeParentChange);
+ d->width = width;
+}
+
+bool QDeclarativeParentChange::widthIsSet() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->width.isValid();
+}
+
+qreal QDeclarativeParentChange::height() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->height.isNull ? qreal(0.) : d->height.value;
+}
+
+void QDeclarativeParentChange::setHeight(qreal height)
+{
+ Q_D(QDeclarativeParentChange);
+ d->height = height;
+}
+
+bool QDeclarativeParentChange::heightIsSet() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->height.isValid();
+}
+
+qreal QDeclarativeParentChange::scale() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->scale.isNull ? qreal(1.) : d->scale.value;
+}
+
+void QDeclarativeParentChange::setScale(qreal scale)
+{
+ Q_D(QDeclarativeParentChange);
+ d->scale = scale;
+}
+
+bool QDeclarativeParentChange::scaleIsSet() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->scale.isValid();
+}
+
+qreal QDeclarativeParentChange::rotation() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->rotation.isNull ? qreal(0.) : d->rotation.value;
+}
+
+void QDeclarativeParentChange::setRotation(qreal rotation)
+{
+ Q_D(QDeclarativeParentChange);
+ d->rotation = rotation;
+}
+
+bool QDeclarativeParentChange::rotationIsSet() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->rotation.isValid();
+}
+
+QDeclarativeItem *QDeclarativeParentChange::originalParent() const
+{
+ Q_D(const QDeclarativeParentChange);
+ return d->origParent;
+}
+
/*!
\qmlproperty Item ParentChange::target
This property holds the item to be reparented
@@ -213,10 +335,43 @@ QDeclarativeStateOperation::ActionList QDeclarativeParentChange::actions()
if (!d->target || !d->parent)
return ActionList();
+ ActionList actions;
+
QDeclarativeAction a;
a.event = this;
+ actions << a;
- return ActionList() << a;
+ if (d->x.isValid()) {
+ QDeclarativeAction xa(d->target, QLatin1String("x"), x());
+ actions << xa;
+ }
+
+ if (d->y.isValid()) {
+ QDeclarativeAction ya(d->target, QLatin1String("y"), y());
+ actions << ya;
+ }
+
+ if (d->scale.isValid()) {
+ QDeclarativeAction sa(d->target, QLatin1String("scale"), scale());
+ actions << sa;
+ }
+
+ if (d->rotation.isValid()) {
+ QDeclarativeAction ra(d->target, QLatin1String("rotation"), rotation());
+ actions << ra;
+ }
+
+ if (d->width.isValid()) {
+ QDeclarativeAction wa(d->target, QLatin1String("width"), width());
+ actions << wa;
+ }
+
+ if (d->height.isValid()) {
+ QDeclarativeAction ha(d->target, QLatin1String("height"), height());
+ actions << ha;
+ }
+
+ return actions;
}
class AccessibleFxItem : public QDeclarativeItem
@@ -661,19 +816,19 @@ QList<QDeclarativeAction> QDeclarativeAnchorChanges::extraActions()
if (d->target) {
QDeclarativeAction a;
a.fromValue = d->fromX;
- a.property = QDeclarativeMetaProperty(d->target, QLatin1String("x"));
+ a.property = QDeclarativeProperty(d->target, QLatin1String("x"));
extra << a;
a.fromValue = d->fromY;
- a.property = QDeclarativeMetaProperty(d->target, QLatin1String("y"));
+ a.property = QDeclarativeProperty(d->target, QLatin1String("y"));
extra << a;
a.fromValue = d->fromWidth;
- a.property = QDeclarativeMetaProperty(d->target, QLatin1String("width"));
+ a.property = QDeclarativeProperty(d->target, QLatin1String("width"));
extra << a;
a.fromValue = d->fromHeight;
- a.property = QDeclarativeMetaProperty(d->target, QLatin1String("height"));
+ a.property = QDeclarativeProperty(d->target, QLatin1String("height"));
extra << a;
}
diff --git a/src/declarative/util/qdeclarativestateoperations_p.h b/src/declarative/util/qdeclarativestateoperations_p.h
index 9204a58..dd4248023 100644
--- a/src/declarative/util/qdeclarativestateoperations_p.h
+++ b/src/declarative/util/qdeclarativestateoperations_p.h
@@ -45,7 +45,7 @@
#include "qdeclarativestate_p.h"
#include <qdeclarativeitem.h>
-#include "private/qdeclarativeanchors_p.h"
+#include <private/qdeclarativeanchors_p.h>
#include <qdeclarativescriptstring.h>
QT_BEGIN_HEADER
@@ -62,6 +62,12 @@ class Q_DECLARATIVE_EXPORT QDeclarativeParentChange : public QDeclarativeStateOp
Q_PROPERTY(QDeclarativeItem *target READ object WRITE setObject)
Q_PROPERTY(QDeclarativeItem *parent READ parent WRITE setParent)
+ Q_PROPERTY(qreal x READ x WRITE setX)
+ Q_PROPERTY(qreal y READ y WRITE setY)
+ Q_PROPERTY(qreal width READ width WRITE setWidth)
+ Q_PROPERTY(qreal height READ height WRITE setHeight)
+ Q_PROPERTY(qreal scale READ scale WRITE setScale)
+ Q_PROPERTY(qreal rotation READ rotation WRITE setRotation)
public:
QDeclarativeParentChange(QObject *parent=0);
~QDeclarativeParentChange();
@@ -72,6 +78,32 @@ public:
QDeclarativeItem *parent() const;
void setParent(QDeclarativeItem *);
+ QDeclarativeItem *originalParent() const;
+
+ qreal x() const;
+ void setX(qreal x);
+ bool xIsSet() const;
+
+ qreal y() const;
+ void setY(qreal y);
+ bool yIsSet() const;
+
+ qreal width() const;
+ void setWidth(qreal width);
+ bool widthIsSet() const;
+
+ qreal height() const;
+ void setHeight(qreal height);
+ bool heightIsSet() const;
+
+ qreal scale() const;
+ void setScale(qreal scale);
+ bool scaleIsSet() const;
+
+ qreal rotation() const;
+ void setRotation(qreal rotation);
+ bool rotationIsSet() const;
+
virtual ActionList actions();
virtual void saveOriginals();
diff --git a/src/declarative/util/qdeclarativesystempalette.cpp b/src/declarative/util/qdeclarativesystempalette.cpp
index 1e00f22..d819c27 100644
--- a/src/declarative/util/qdeclarativesystempalette.cpp
+++ b/src/declarative/util/qdeclarativesystempalette.cpp
@@ -58,6 +58,7 @@ public:
/*!
\qmlclass SystemPalette QDeclarativeSystemPalette
+ \since 4.7
\ingroup group_utility
\brief The SystemPalette item gives access to the Qt palettes.
\sa QPalette
diff --git a/src/declarative/util/qdeclarativetimer.cpp b/src/declarative/util/qdeclarativetimer.cpp
index 89c461b..d7e02b1 100644
--- a/src/declarative/util/qdeclarativetimer.cpp
+++ b/src/declarative/util/qdeclarativetimer.cpp
@@ -70,6 +70,7 @@ public:
/*!
\qmlclass Timer QDeclarativeTimer
+ \since 4.7
\brief The Timer item triggers a handler at a specified interval.
A timer can be used to trigger an action either once, or repeatedly
diff --git a/src/declarative/util/qdeclarativetransition.cpp b/src/declarative/util/qdeclarativetransition.cpp
index 3482814..ac07b10 100644
--- a/src/declarative/util/qdeclarativetransition.cpp
+++ b/src/declarative/util/qdeclarativetransition.cpp
@@ -148,7 +148,7 @@ void QDeclarativeTransition::setReversed(bool r)
}
void QDeclarativeTransition::prepare(QDeclarativeStateOperation::ActionList &actions,
- QList<QDeclarativeMetaProperty> &after,
+ QList<QDeclarativeProperty> &after,
QDeclarativeTransitionManager *endState)
{
Q_D(QDeclarativeTransition);
diff --git a/src/declarative/util/qdeclarativetransition_p.h b/src/declarative/util/qdeclarativetransition_p.h
index 96448b8..861111a 100644
--- a/src/declarative/util/qdeclarativetransition_p.h
+++ b/src/declarative/util/qdeclarativetransition_p.h
@@ -85,7 +85,7 @@ public:
QDeclarativeListProperty<QDeclarativeAbstractAnimation> animations();
void prepare(QDeclarativeStateOperation::ActionList &actions,
- QList<QDeclarativeMetaProperty> &after,
+ QList<QDeclarativeProperty> &after,
QDeclarativeTransitionManager *end);
void setReversed(bool r);
diff --git a/src/declarative/util/qdeclarativetransitionmanager.cpp b/src/declarative/util/qdeclarativetransitionmanager.cpp
index 6429dab..e1143fa 100644
--- a/src/declarative/util/qdeclarativetransitionmanager.cpp
+++ b/src/declarative/util/qdeclarativetransitionmanager.cpp
@@ -45,7 +45,7 @@
#include <qdeclarativebinding_p.h>
#include <qdeclarativeglobal_p.h>
-#include <qdeclarativemetaproperty_p.h>
+#include <qdeclarativeproperty_p.h>
QT_BEGIN_NAMESPACE
@@ -85,7 +85,7 @@ void QDeclarativeTransitionManager::complete()
d->applyBindings();
for (int ii = 0; ii < d->completeList.count(); ++ii) {
- const QDeclarativeMetaProperty &prop = d->completeList.at(ii).property;
+ const QDeclarativeProperty &prop = d->completeList.at(ii).property;
prop.write(d->completeList.at(ii).value);
}
@@ -99,7 +99,7 @@ void QDeclarativeTransitionManagerPrivate::applyBindings()
{
foreach(const QDeclarativeAction &action, bindingsList) {
if (action.toBinding) {
- QDeclarativeMetaPropertyPrivate::setBinding(action.property, action.toBinding);
+ QDeclarativePropertyPrivate::setBinding(action.property, action.toBinding);
} else if (action.event) {
if (action.reverseEvent)
action.event->reverse();
@@ -123,7 +123,7 @@ void QDeclarativeTransitionManager::transition(const QList<QDeclarativeAction> &
if (action.toBinding)
d->bindingsList << action;
if (action.fromBinding)
- QDeclarativeMetaPropertyPrivate::setBinding(action.property, 0); // Disable current binding
+ QDeclarativePropertyPrivate::setBinding(action.property, 0); // Disable current binding
if (action.event && action.event->changesBindings()) { //### assume isReversable()?
d->bindingsList << action;
if (action.reverseEvent)
@@ -150,9 +150,9 @@ void QDeclarativeTransitionManager::transition(const QList<QDeclarativeAction> &
for (int ii = 0; ii < applyList.size(); ++ii) {
const QDeclarativeAction &action = applyList.at(ii);
if (action.toBinding) {
- QDeclarativeMetaPropertyPrivate::setBinding(action.property, action.toBinding, QDeclarativeMetaPropertyPrivate::BypassInterceptor | QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ QDeclarativePropertyPrivate::setBinding(action.property, action.toBinding, QDeclarativePropertyPrivate::BypassInterceptor | QDeclarativePropertyPrivate::DontRemoveBinding);
} else if (!action.event) {
- QDeclarativeMetaPropertyPrivate::write(action.property, action.toValue, QDeclarativeMetaPropertyPrivate::BypassInterceptor | QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ QDeclarativePropertyPrivate::write(action.property, action.toValue, QDeclarativePropertyPrivate::BypassInterceptor | QDeclarativePropertyPrivate::DontRemoveBinding);
} else if (action.event->isReversable()) {
if (action.reverseEvent)
action.event->reverse();
@@ -167,7 +167,7 @@ void QDeclarativeTransitionManager::transition(const QList<QDeclarativeAction> &
QDeclarativeAction *action = &applyList[ii];
if (action->event)
continue;
- const QDeclarativeMetaProperty &prop = action->property;
+ const QDeclarativeProperty &prop = action->property;
if (action->toBinding || !action->toValue.isValid()) { //### is this always right (used for exta actions)
action->toValue = prop.read();
}
@@ -191,14 +191,14 @@ void QDeclarativeTransitionManager::transition(const QList<QDeclarativeAction> &
}
if (action.toBinding)
- QDeclarativeMetaPropertyPrivate::setBinding(action.property, 0); // Make sure this is disabled during the transition
+ QDeclarativePropertyPrivate::setBinding(action.property, 0); // Make sure this is disabled during the transition
- QDeclarativeMetaPropertyPrivate::write(action.property, action.fromValue, QDeclarativeMetaPropertyPrivate::BypassInterceptor | QDeclarativeMetaPropertyPrivate::DontRemoveBinding);
+ QDeclarativePropertyPrivate::write(action.property, action.fromValue, QDeclarativePropertyPrivate::BypassInterceptor | QDeclarativePropertyPrivate::DontRemoveBinding);
}
}
if (transition) {
- QList<QDeclarativeMetaProperty> touched;
+ QList<QDeclarativeProperty> touched;
d->transition = transition;
d->transition->prepare(applyList, touched, this);
@@ -267,7 +267,7 @@ void QDeclarativeTransitionManager::cancel()
for(int i = 0; i < d->bindingsList.count(); ++i) {
QDeclarativeAction action = d->bindingsList[i];
if (action.toBinding && action.deletableToBinding) {
- QDeclarativeMetaPropertyPrivate::setBinding(action.property, 0);
+ QDeclarativePropertyPrivate::setBinding(action.property, 0);
action.toBinding->destroy();
action.toBinding = 0;
action.deletableToBinding = false;
diff --git a/src/declarative/util/qdeclarativeutilmodule.cpp b/src/declarative/util/qdeclarativeutilmodule.cpp
index ecaa607c..2b8c7de 100644
--- a/src/declarative/util/qdeclarativeutilmodule.cpp
+++ b/src/declarative/util/qdeclarativeutilmodule.cpp
@@ -45,7 +45,7 @@
#include "qdeclarativeanimation_p_p.h"
#include "qdeclarativebehavior_p.h"
#include "qdeclarativebind_p.h"
-#include "qdeclarativeconnection_p.h"
+#include "qdeclarativeconnections_p.h"
#include "qdeclarativedatetimeformatter_p.h"
#include "qdeclarativeeasefollow_p.h"
#include "qdeclarativefontloader_p.h"
@@ -80,7 +80,7 @@ void QDeclarativeUtilModule::defineModule()
QML_REGISTER_TYPE(Qt,4,6,Behavior,QDeclarativeBehavior);
QML_REGISTER_TYPE(Qt,4,6,Binding,QDeclarativeBind);
QML_REGISTER_TYPE(Qt,4,6,ColorAnimation,QDeclarativeColorAnimation);
- QML_REGISTER_TYPE(Qt,4,6,Connection,QDeclarativeConnection);
+ QML_REGISTER_TYPE(Qt,4,6,Connections,QDeclarativeConnections);
QML_REGISTER_TYPE(Qt,4,6,DateTimeFormatter,QDeclarativeDateTimeFormatter);
QML_REGISTER_TYPE(Qt,4,6,EaseFollow,QDeclarativeEaseFollow);;
QML_REGISTER_TYPE(Qt,4,6,FontLoader,QDeclarativeFontLoader);
@@ -90,6 +90,7 @@ void QDeclarativeUtilModule::defineModule()
QML_REGISTER_TYPE(Qt,4,6,Package,QDeclarativePackage);
QML_REGISTER_TYPE(Qt,4,6,ParallelAnimation,QDeclarativeParallelAnimation);
QML_REGISTER_TYPE(Qt,4,6,ParentAction,QDeclarativeParentAction);
+ QML_REGISTER_TYPE(Qt,4,6,ParentAnimation,QDeclarativeParentAnimation);
QML_REGISTER_TYPE(Qt,4,6,ParentChange,QDeclarativeParentChange);
QML_REGISTER_TYPE(Qt,4,6,PauseAnimation,QDeclarativePauseAnimation);
QML_REGISTER_TYPE(Qt,4,6,PropertyAction,QDeclarativePropertyAction);
@@ -117,4 +118,5 @@ void QDeclarativeUtilModule::defineModule()
QML_REGISTER_CUSTOM_TYPE(Qt, 4,6, ListModel, QDeclarativeListModel, QDeclarativeListModelParser);
QML_REGISTER_CUSTOM_TYPE(Qt, 4,6, PropertyChanges, QDeclarativePropertyChanges, QDeclarativePropertyChangesParser);
+ QML_REGISTER_CUSTOM_TYPE(Qt, 4,6, Connections, QDeclarativeConnections, QDeclarativeConnectionsParser);
}
diff --git a/src/declarative/util/qdeclarativexmllistmodel.cpp b/src/declarative/util/qdeclarativexmllistmodel.cpp
index 386df46..162a669 100644
--- a/src/declarative/util/qdeclarativexmllistmodel.cpp
+++ b/src/declarative/util/qdeclarativexmllistmodel.cpp
@@ -709,8 +709,24 @@ void QDeclarativeXmlListModel::reload()
d->qmlXmlQuery.abort();
d->queryId = -1;
- if (d->size < 0)
+ int count = d->size;
+ if (count < 0)
d->size = 0;
+ bool hasKeys = false;
+ for (int i=0; i<d->roleObjects.count(); i++) {
+ if (d->roleObjects[i]->isKey()) {
+ hasKeys = true;
+ break;
+ }
+ }
+ if (!hasKeys) {
+ d->data.clear();
+ d->size = 0;
+ if (count > 0) {
+ emit itemsRemoved(0, count);
+ emit countChanged();
+ }
+ }
if (d->src.isEmpty() && d->xml.isEmpty())
return;
@@ -782,9 +798,10 @@ void QDeclarativeXmlListModel::queryCompleted(int id, int size)
d->data = d->qmlXmlQuery.modelData();
QList<QDeclarativeXmlListRange> removed = d->qmlXmlQuery.removedItemRanges();
+ QList<QDeclarativeXmlListRange> inserted = d->qmlXmlQuery.insertedItemRanges();
+
for (int i=0; i<removed.count(); i++)
emit itemsRemoved(removed[i].first, removed[i].second);
- QList<QDeclarativeXmlListRange> inserted = d->qmlXmlQuery.insertedItemRanges();
for (int i=0; i<inserted.count(); i++)
emit itemsInserted(inserted[i].first, inserted[i].second);
diff --git a/src/declarative/util/qdeclarativexmllistmodel_p.h b/src/declarative/util/qdeclarativexmllistmodel_p.h
index 132a53c..f0ad4b8 100644
--- a/src/declarative/util/qdeclarativexmllistmodel_p.h
+++ b/src/declarative/util/qdeclarativexmllistmodel_p.h
@@ -47,7 +47,7 @@
#include <QtCore/qurl.h>
-#include "../3rdparty/qlistmodelinterface_p.h"
+#include <private/qlistmodelinterface_p.h>
QT_BEGIN_HEADER
diff --git a/src/declarative/util/util.pri b/src/declarative/util/util.pri
index 610eb3f..198e9e5 100644
--- a/src/declarative/util/util.pri
+++ b/src/declarative/util/util.pri
@@ -5,7 +5,7 @@ SOURCES += \
$$PWD/qdeclarativeview.cpp \
$$PWD/qfxperf.cpp \
$$PWD/qperformancelog.cpp \
- $$PWD/qdeclarativeconnection.cpp \
+ $$PWD/qdeclarativeconnections.cpp \
$$PWD/qdeclarativepackage.cpp \
$$PWD/qdeclarativeanimation.cpp \
$$PWD/qdeclarativesystempalette.cpp \
@@ -37,7 +37,7 @@ HEADERS += \
$$PWD/qdeclarativeview.h \
$$PWD/qfxperf_p_p.h \
$$PWD/qperformancelog_p_p.h \
- $$PWD/qdeclarativeconnection_p.h \
+ $$PWD/qdeclarativeconnections_p.h \
$$PWD/qdeclarativepackage_p.h \
$$PWD/qdeclarativeanimation_p.h \
$$PWD/qdeclarativeanimation_p_p.h \