diff options
author | Aaron Kennedy <aaron.kennedy@nokia.com> | 2010-03-11 00:21:38 (GMT) |
---|---|---|
committer | Aaron Kennedy <aaron.kennedy@nokia.com> | 2010-03-11 00:21:38 (GMT) |
commit | c62cd5347adda26a68b3a2a67e04a38c0e8626fe (patch) | |
tree | 9caf5ef30fb88e17b7153580067d9c8933308ee7 /src/declarative/util | |
parent | dd7230279bf22fe34f04aa7d216b6d2fb60db720 (diff) | |
parent | 1c76ce32af211250935db7af8fa6f6e3e8afd01c (diff) | |
download | Qt-c62cd5347adda26a68b3a2a67e04a38c0e8626fe.zip Qt-c62cd5347adda26a68b3a2a67e04a38c0e8626fe.tar.gz Qt-c62cd5347adda26a68b3a2a67e04a38c0e8626fe.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-qml into 4.7
Conflicts:
src/declarative/qml/qdeclarativepropertycache.cpp
src/declarative/qml/qdeclarativepropertycache_p.h
Diffstat (limited to 'src/declarative/util')
-rw-r--r-- | src/declarative/util/qdeclarativeanimation.cpp | 8 | ||||
-rw-r--r-- | src/declarative/util/qdeclarativeutilmodule.cpp | 75 | ||||
-rw-r--r-- | src/declarative/util/qdeclarativeview.cpp | 19 |
3 files changed, 59 insertions, 43 deletions
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/qdeclarativeutilmodule.cpp b/src/declarative/util/qdeclarativeutilmodule.cpp index 65bfdc1..9c3b0aa 100644 --- a/src/declarative/util/qdeclarativeutilmodule.cpp +++ b/src/declarative/util/qdeclarativeutilmodule.cpp @@ -75,44 +75,47 @@ void QDeclarativeUtilModule::defineModule() { - QML_REGISTER_TYPE(Qt,4,6,AnchorChanges,QDeclarativeAnchorChanges); - 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,Connections,QDeclarativeConnections); - QML_REGISTER_TYPE(Qt,4,6,EaseFollow,QDeclarativeEaseFollow);; - QML_REGISTER_TYPE(Qt,4,6,FontLoader,QDeclarativeFontLoader); - QML_REGISTER_TYPE(Qt,4,6,ListElement,QDeclarativeListElement); - QML_REGISTER_TYPE(Qt,4,6,NumberAnimation,QDeclarativeNumberAnimation); - 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); - QML_REGISTER_TYPE(Qt,4,6,PropertyAnimation,QDeclarativePropertyAnimation); - QML_REGISTER_TYPE(Qt,4,6,RotationAnimation,QDeclarativeRotationAnimation); - QML_REGISTER_TYPE(Qt,4,6,ScriptAction,QDeclarativeScriptAction); - QML_REGISTER_TYPE(Qt,4,6,SequentialAnimation,QDeclarativeSequentialAnimation); - QML_REGISTER_TYPE(Qt,4,6,SpringFollow,QDeclarativeSpringFollow); - QML_REGISTER_TYPE(Qt,4,6,StateChangeScript,QDeclarativeStateChangeScript); - QML_REGISTER_TYPE(Qt,4,6,StateGroup,QDeclarativeStateGroup); - QML_REGISTER_TYPE(Qt,4,6,State,QDeclarativeState); - QML_REGISTER_TYPE(Qt,4,6,SystemPalette,QDeclarativeSystemPalette); - QML_REGISTER_TYPE(Qt,4,6,Timer,QDeclarativeTimer); - QML_REGISTER_TYPE(Qt,4,6,Transition,QDeclarativeTransition); - QML_REGISTER_TYPE(Qt,4,6,Vector3dAnimation,QDeclarativeVector3dAnimation); + qmlRegisterType<QDeclarativeAnchorChanges>("Qt",4,6,"AnchorChanges"); + qmlRegisterType<QDeclarativeBehavior>("Qt",4,6,"Behavior"); + qmlRegisterType<QDeclarativeBind>("Qt",4,6,"Binding"); + qmlRegisterType<QDeclarativeColorAnimation>("Qt",4,6,"ColorAnimation"); + qmlRegisterType<QDeclarativeConnections>("Qt",4,6,"Connections"); + qmlRegisterType<QDeclarativeEaseFollow>("Qt",4,6,"EaseFollow"); + qmlRegisterType<QDeclarativeFontLoader>("Qt",4,6,"FontLoader"); + qmlRegisterType<QDeclarativeListElement>("Qt",4,6,"ListElement"); + qmlRegisterType<QDeclarativeNumberAnimation>("Qt",4,6,"NumberAnimation"); + qmlRegisterType<QDeclarativePackage>("Qt",4,6,"Package"); + qmlRegisterType<QDeclarativeParallelAnimation>("Qt",4,6,"ParallelAnimation"); + qmlRegisterType<QDeclarativeParentAction>("Qt",4,6,"ParentAction"); + qmlRegisterType<QDeclarativeParentAnimation>("Qt",4,6,"ParentAnimation"); + qmlRegisterType<QDeclarativeParentChange>("Qt",4,6,"ParentChange"); + qmlRegisterType<QDeclarativePauseAnimation>("Qt",4,6,"PauseAnimation"); + qmlRegisterType<QDeclarativePropertyAction>("Qt",4,6,"PropertyAction"); + qmlRegisterType<QDeclarativePropertyAnimation>("Qt",4,6,"PropertyAnimation"); + qmlRegisterType<QDeclarativeRotationAnimation>("Qt",4,6,"RotationAnimation"); + qmlRegisterType<QDeclarativeScriptAction>("Qt",4,6,"ScriptAction"); + qmlRegisterType<QDeclarativeSequentialAnimation>("Qt",4,6,"SequentialAnimation"); + qmlRegisterType<QDeclarativeSpringFollow>("Qt",4,6,"SpringFollow"); + qmlRegisterType<QDeclarativeStateChangeScript>("Qt",4,6,"StateChangeScript"); + qmlRegisterType<QDeclarativeStateGroup>("Qt",4,6,"StateGroup"); + qmlRegisterType<QDeclarativeState>("Qt",4,6,"State"); + qmlRegisterType<QDeclarativeSystemPalette>("Qt",4,6,"SystemPalette"); + qmlRegisterType<QDeclarativeTimer>("Qt",4,6,"Timer"); + qmlRegisterType<QDeclarativeTransition>("Qt",4,6,"Transition"); + qmlRegisterType<QDeclarativeVector3dAnimation>("Qt",4,6,"Vector3dAnimation"); #ifndef QT_NO_XMLPATTERNS - QML_REGISTER_TYPE(Qt,4,6,XmlListModel,QDeclarativeXmlListModel); - QML_REGISTER_TYPE(Qt,4,6,XmlRole,QDeclarativeXmlListModelRole); + qmlRegisterType<QDeclarativeXmlListModel>("Qt",4,6,"XmlListModel"); + qmlRegisterType<QDeclarativeXmlListModelRole>("Qt",4,6,"XmlRole"); #endif - QML_REGISTER_NOCREATE_TYPE(QDeclarativeAnchors); - QML_REGISTER_NOCREATE_TYPE(QDeclarativeAbstractAnimation); - QML_REGISTER_NOCREATE_TYPE(QDeclarativeStateOperation); + qmlRegisterType<QDeclarativeAnchors>(); + qmlRegisterType<QDeclarativeAbstractAnimation>(); + qmlRegisterType<QDeclarativeStateOperation>(); - 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); + qmlRegisterCustomType<QDeclarativeListModel>("Qt", 4,6, "ListModel", "QDeclarativeListModel", + new QDeclarativeListModelParser); + qmlRegisterCustomType<QDeclarativePropertyChanges>("Qt", 4, 6, "PropertyChanges", "QDeclarativePropertyChanges", + new QDeclarativePropertyChangesParser); + qmlRegisterCustomType<QDeclarativeConnections>("Qt", 4, 6, "Connections", "QDeclarativeConnections", + new QDeclarativeConnectionsParser); } 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) |