summaryrefslogtreecommitdiffstats
path: root/src/declarative
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-03-10 10:33:34 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-03-10 10:33:34 (GMT)
commit0d6d25e6796a85ea44d982a8ec618d920371c7a9 (patch)
tree71b497a5370b0707b4da324b6918bce7f4901879 /src/declarative
parent878c2a984b78cdfc88e4474f6719f07662c7ac68 (diff)
parent12d63b05a942281e688d857d17c190564c77b698 (diff)
downloadQt-0d6d25e6796a85ea44d982a8ec618d920371c7a9.zip
Qt-0d6d25e6796a85ea44d982a8ec618d920371c7a9.tar.gz
Qt-0d6d25e6796a85ea44d982a8ec618d920371c7a9.tar.bz2
Merge remote branch 'qt/4.7' into qml-4.7
Conflicts: src/declarative/util/qdeclarativestateoperations.cpp
Diffstat (limited to 'src/declarative')
-rw-r--r--src/declarative/graphicsitems/qdeclarativeitem.cpp10
-rw-r--r--src/declarative/qml/qdeclarativeengine.cpp10
-rw-r--r--src/declarative/qml/qdeclarativeexpression.cpp27
-rw-r--r--src/declarative/qml/qdeclarativeextensionplugin.cpp2
-rw-r--r--src/declarative/qml/qdeclarativeimageprovider.cpp4
-rw-r--r--src/declarative/qml/qdeclarativeproperty.cpp83
-rw-r--r--src/declarative/util/qdeclarativeanimation.cpp8
-rw-r--r--src/declarative/util/qdeclarativeview.cpp19
8 files changed, 109 insertions, 54 deletions
diff --git a/src/declarative/graphicsitems/qdeclarativeitem.cpp b/src/declarative/graphicsitems/qdeclarativeitem.cpp
index 7c6c46b..4ba80ad 100644
--- a/src/declarative/graphicsitems/qdeclarativeitem.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeitem.cpp
@@ -1293,6 +1293,16 @@ QDeclarativeKeysAttached *QDeclarativeKeysAttached::qmlAttachedProperties(QObjec
\internal
*/
+/*!
+ \fn void QDeclarativeItem::smoothChanged()
+ \internal
+*/
+
+/*!
+ \fn void QDeclarativeItem::clipChanged()
+ \internal
+*/
+
/*! \fn void QDeclarativeItem::transformOriginChanged(TransformOrigin)
\internal
*/
diff --git a/src/declarative/qml/qdeclarativeengine.cpp b/src/declarative/qml/qdeclarativeengine.cpp
index 791df9f..6325466 100644
--- a/src/declarative/qml/qdeclarativeengine.cpp
+++ b/src/declarative/qml/qdeclarativeengine.cpp
@@ -542,9 +542,9 @@ QNetworkAccessManager *QDeclarativeEngine::networkAccessManager() const
This example creates a provider with id \e colors:
- \snippet examples/declarative/imageprovider/main.cpp 0
+ \snippet examples/declarative/imageprovider/imageprovider.cpp 0
- \snippet examples/declarative/imageprovider/view.qml 0
+ \snippet examples/declarative/imageprovider/imageprovider.qml 0
\sa removeImageProvider()
*/
@@ -1716,10 +1716,8 @@ void QDeclarativeEngine::addImportPath(const QString& path)
}
/*!
- Imports the given \a extension into this QDeclarativeEngine. Returns
- true if the extension was successfully imported.
-
- \sa QDeclarativeExtensionInterface
+ Imports the extension named \a fileName from the \a uri provided.
+ Returns true if the extension was successfully imported.
*/
bool QDeclarativeEngine::importExtension(const QString &fileName, const QString &uri)
{
diff --git a/src/declarative/qml/qdeclarativeexpression.cpp b/src/declarative/qml/qdeclarativeexpression.cpp
index 207ded6..5ff22f7 100644
--- a/src/declarative/qml/qdeclarativeexpression.cpp
+++ b/src/declarative/qml/qdeclarativeexpression.cpp
@@ -512,19 +512,20 @@ bool QDeclarativeExpression::notifyOnValueChanged() const
}
/*!
-Sets whether the valueChanged() signal is emitted when the expression's evaluated
-value changes.
-
-If true, the QDeclarativeExpression will monitor properties involved in the expression's
-evaluation, and emit QDeclarativeExpression::valueChanged() if they have changed. This allows
-an application to ensure that any value associated with the result of the expression
-remains up to date.
-
-If false, the QDeclarativeExpression will not montitor properties involved in the expression's
-evaluation, and QDeclarativeExpression::valueChanged() will never be emitted. This is more efficient
-if an application wants a "one off" evaluation of the expression.
-
-By default, notifyOnChange is false.
+ Sets whether the valueChanged() signal is emitted when the
+ expression's evaluated value changes.
+
+ If \a notifyOnChange is true, the QDeclarativeExpression will
+ monitor properties involved in the expression's evaluation, and emit
+ QDeclarativeExpression::valueChanged() if they have changed. This
+ allows an application to ensure that any value associated with the
+ result of the expression remains up to date.
+
+ If \a notifyOnChange is false (default), the QDeclarativeExpression
+ will not montitor properties involved in the expression's
+ evaluation, and QDeclarativeExpression::valueChanged() will never be
+ emitted. This is more efficient if an application wants a "one off"
+ evaluation of the expression.
*/
void QDeclarativeExpression::setNotifyOnValueChanged(bool notifyOnChange)
{
diff --git a/src/declarative/qml/qdeclarativeextensionplugin.cpp b/src/declarative/qml/qdeclarativeextensionplugin.cpp
index 3d44d63..7617977 100644
--- a/src/declarative/qml/qdeclarativeextensionplugin.cpp
+++ b/src/declarative/qml/qdeclarativeextensionplugin.cpp
@@ -87,7 +87,7 @@ QDeclarativeExtensionPlugin::~QDeclarativeExtensionPlugin()
/*!
\fn void QDeclarativeExtensionPlugin::initializeEngine(QDeclarativeEngine *engine, const char *uri)
- Initializes the extension specified in the given \a engine.
+ Initializes the extension from the \a uri using the \a engine.
*/
void QDeclarativeExtensionPlugin::initializeEngine(QDeclarativeEngine *engine, const char *uri)
diff --git a/src/declarative/qml/qdeclarativeimageprovider.cpp b/src/declarative/qml/qdeclarativeimageprovider.cpp
index daa2e87..9ef8545 100644
--- a/src/declarative/qml/qdeclarativeimageprovider.cpp
+++ b/src/declarative/qml/qdeclarativeimageprovider.cpp
@@ -52,6 +52,10 @@ QT_BEGIN_NAMESPACE
\sa QDeclarativeEngine::addImageProvider()
*/
+
+/*!
+ The destructor is virtual.
+ */
QDeclarativeImageProvider::~QDeclarativeImageProvider()
{
}
diff --git a/src/declarative/qml/qdeclarativeproperty.cpp b/src/declarative/qml/qdeclarativeproperty.cpp
index 4f73b89..945d098 100644
--- a/src/declarative/qml/qdeclarativeproperty.cpp
+++ b/src/declarative/qml/qdeclarativeproperty.cpp
@@ -115,8 +115,10 @@ QDeclarativeProperty::QDeclarativeProperty(QObject *obj)
}
/*!
- Creates a QDeclarativeProperty for the default property of \a obj. If there is no
- default property, an invalid QDeclarativeProperty will be created.
+ Creates a QDeclarativeProperty for the default property of \a obj
+ using the \l{QDeclarativeContext} {context} \a ctxt. If there is
+ no default property, an invalid QDeclarativeProperty will be
+ created.
*/
QDeclarativeProperty::QDeclarativeProperty(QObject *obj, QDeclarativeContext *ctxt)
: d(new QDeclarativePropertyPrivate)
@@ -128,11 +130,13 @@ QDeclarativeProperty::QDeclarativeProperty(QObject *obj, QDeclarativeContext *ct
}
/*!
- Creates a QDeclarativeProperty for the default property of \a obj. If there is no
- default property, an invalid QDeclarativeProperty will be created.
+ Creates a QDeclarativeProperty for the default property of \a obj
+ using the environment for instantiating QML components that is
+ provided by \a engine. If there is no default property, an
+ invalid QDeclarativeProperty will be created.
*/
QDeclarativeProperty::QDeclarativeProperty(QObject *obj, QDeclarativeEngine *engine)
-: d(new QDeclarativePropertyPrivate)
+ : d(new QDeclarativePropertyPrivate)
{
d->q = this;
d->context = 0;
@@ -166,8 +170,9 @@ QDeclarativeProperty::QDeclarativeProperty(QObject *obj, const QString &name)
}
/*!
- Creates a QDeclarativeProperty for the property \a name of \a obj.
- */
+ Creates a QDeclarativeProperty for the property \a name of \a obj
+ using the \l{QDeclarativeContext} {context} \a ctxt.
+*/
QDeclarativeProperty::QDeclarativeProperty(QObject *obj, const QString &name, QDeclarativeContext *ctxt)
: d(new QDeclarativePropertyPrivate)
{
@@ -179,7 +184,9 @@ QDeclarativeProperty::QDeclarativeProperty(QObject *obj, const QString &name, QD
}
/*!
- Creates a QDeclarativeProperty for the property \a name of \a obj.
+ Creates a QDeclarativeProperty for the property \a name of \a obj
+ using the environment for instantiating QML components that is
+ provided by \a engine.
*/
QDeclarativeProperty::QDeclarativeProperty(QObject *obj, const QString &name, QDeclarativeEngine *engine)
: d(new QDeclarativePropertyPrivate)
@@ -766,11 +773,14 @@ QVariant QDeclarativeProperty::read(QObject *object, const QString &name)
}
/*!
-Return the \a name property value of \a object. This method is equivalent to:
-\code
+ Return the \a name property value of \a object using the
+ \l{QDeclarativeContext} {context} \a ctxt. This method is
+ equivalent to:
+
+ \code
QDeclarativeProperty p(object, name, context);
p.read();
-\endcode
+ \endcode
*/
QVariant QDeclarativeProperty::read(QObject *object, const QString &name, QDeclarativeContext *ctxt)
{
@@ -779,11 +789,15 @@ QVariant QDeclarativeProperty::read(QObject *object, const QString &name, QDecla
}
/*!
-Return the \a name property value of \a object. This method is equivalent to:
-\code
+
+ Return the \a name property value of \a object using the environment
+ for instantiating QML components that is provided by \a engine. .
+ This method is equivalent to:
+
+ \code
QDeclarativeProperty p(object, name, engine);
p.read();
-\endcode
+ \endcode
*/
QVariant QDeclarativeProperty::read(QObject *object, const QString &name, QDeclarativeEngine *engine)
{
@@ -1073,19 +1087,23 @@ const QMetaObject *QDeclarativePropertyPrivate::rawMetaObjectForType(QDeclarativ
}
/*!
- Set the property value to \a value.
-*/
+ Sets the property value to \a value and returns true.
+ Returns false if the property can't be set because the
+ \a value is the wrong type, for example.
+ */
bool QDeclarativeProperty::write(const QVariant &value) const
{
return QDeclarativePropertyPrivate::write(*this, value, 0);
}
/*!
-Writes \a value to the \a name property of \a object. This method is equivalent to:
-\code
+ 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
+ \endcode
*/
bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVariant &value)
{
@@ -1094,13 +1112,18 @@ bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVa
}
/*!
-Writes \a value to the \a name property of \a object. This method is equivalent to:
-\code
+ Writes \a value to the \a name property of \a object using the
+ \l{QDeclarativeContext} {context} \a ctxt. This method is
+ equivalent to:
+
+ \code
QDeclarativeProperty p(object, name, ctxt);
p.write(value);
-\endcode
+ \endcode
*/
-bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVariant &value,
+bool QDeclarativeProperty::write(QObject *object,
+ const QString &name,
+ const QVariant &value,
QDeclarativeContext *ctxt)
{
QDeclarativeProperty p(object, name, ctxt);
@@ -1108,11 +1131,15 @@ bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVa
}
/*!
-Writes \a value to the \a name property of \a object. This method is equivalent to:
-\code
+
+ Writes \a value to the \a name property of \a object using the
+ environment for instantiating QML components that is provided by
+ \a engine. This method is equivalent to:
+
+ \code
QDeclarativeProperty p(object, name, engine);
p.write(value);
-\endcode
+ \endcode
*/
bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVariant &value,
QDeclarativeEngine *engine)
@@ -1122,7 +1149,9 @@ bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVa
}
/*!
- Resets the property value.
+ Resets the property and returns true if the property is
+ resettable. If the property is not resettable, nothing happens
+ and false is returned.
*/
bool QDeclarativeProperty::reset() const
{
diff --git a/src/declarative/util/qdeclarativeanimation.cpp b/src/declarative/util/qdeclarativeanimation.cpp
index 8c8dd95..20449d7 100644
--- a/src/declarative/util/qdeclarativeanimation.cpp
+++ b/src/declarative/util/qdeclarativeanimation.cpp
@@ -838,10 +838,10 @@ void QDeclarativePropertyAction::setProperty(const QString &n)
}
/*!
+ \qmlproperty list<Object> PropertyAction::targets
\qmlproperty string PropertyAction::property
\qmlproperty string PropertyAction::properties
\qmlproperty Object PropertyAction::target
- \qmlproperty list<Object> PropertyAction::targets
These properties are used as a set to determine which properties should be
affected by this action.
@@ -876,6 +876,7 @@ QDeclarativeListProperty<QObject> QDeclarativePropertyAction::targets()
/*!
\qmlproperty list<Object> PropertyAction::exclude
This property holds the objects not to be affected by this animation.
+
\sa targets
*/
QDeclarativeListProperty<QObject> QDeclarativePropertyAction::exclude()
@@ -2220,7 +2221,7 @@ QDeclarativeListProperty<QObject> QDeclarativePropertyAnimation::targets()
/*!
\qmlproperty list<Object> PropertyAnimation::exclude
This property holds the items not to be affected by this animation.
- \sa targets
+ \sa PropertyAnimation::targets
*/
QDeclarativeListProperty<QObject> QDeclarativePropertyAnimation::exclude()
{
@@ -2428,11 +2429,12 @@ void QDeclarativePropertyAnimation::transition(QDeclarativeStateActions &actions
be run in parallel (like those in a ParallelAnimation group).
In some cases, such as reparenting between items with clipping, it's useful
- to animate the parent change \i via another item with no clipping.
+ to animate the parent change via another item with no clipping.
When used in a transition, ParentAnimation will by default animate
all ParentChanges.
*/
+
/*!
\internal
\class QDeclarativeParentAnimation
diff --git a/src/declarative/util/qdeclarativeview.cpp b/src/declarative/util/qdeclarativeview.cpp
index 218b587..486553a 100644
--- a/src/declarative/util/qdeclarativeview.cpp
+++ b/src/declarative/util/qdeclarativeview.cpp
@@ -221,7 +221,7 @@ void QDeclarativeViewPrivate::execute()
*/
/*! \fn void QDeclarativeView::statusChanged(QDeclarativeView::Status status)
- This signal is emitted when the component's current \l{QDeclarativeView::Status} {status} changes.
+ This signal is emitted when the component's current \a status changes.
*/
/*!
@@ -283,6 +283,12 @@ QDeclarativeView::~QDeclarativeView()
delete d->root;
}
+/*! \property QDeclarativeView::source
+ \brief The URL of the source of the QML component.
+
+ Changing this property causes the QML component to be reloaded.
+ */
+
/*!
Sets the source to the \a url, loads the QML component and instantiates it.
@@ -326,7 +332,6 @@ QDeclarativeContext* QDeclarativeView::rootContext()
return d->engine.rootContext();
}
-
/*!
\enum QDeclarativeView::Status
@@ -338,6 +343,14 @@ QDeclarativeContext* QDeclarativeView::rootContext()
\value Error An error has occured. Calling errorDescription() to retrieve a description.
*/
+/*! \enum QDeclarativeView::ResizeMode
+
+ This enum specifies how to resize the view.
+
+ \value SizeViewToRootObject
+ \value SizeRootObjectToView
+*/
+
/*!
\property QDeclarativeView::status
The component's current \l{QDeclarativeView::Status} {status}.
@@ -376,8 +389,6 @@ QList<QDeclarativeError> QDeclarativeView::errors() const
Regardless of this property, the sizeHint of the view
is the initial size of the root item. Note though that
since QML may load dynamically, that size may change.
-
- \sa initialSize()
*/
void QDeclarativeView::setResizeMode(ResizeMode mode)