summaryrefslogtreecommitdiffstats
path: root/src/declarative
diff options
context:
space:
mode:
Diffstat (limited to 'src/declarative')
-rw-r--r--src/declarative/graphicsitems/qdeclarativepathview.cpp6
-rw-r--r--src/declarative/qml/qdeclarativeimageprovider.cpp8
-rw-r--r--src/declarative/qml/qdeclarativelist.h8
-rw-r--r--src/declarative/qml/qdeclarativeprivate.h4
-rw-r--r--src/declarative/util/qdeclarativeanimation.cpp2
-rw-r--r--src/declarative/util/qdeclarativetransition.cpp2
6 files changed, 15 insertions, 15 deletions
diff --git a/src/declarative/graphicsitems/qdeclarativepathview.cpp b/src/declarative/graphicsitems/qdeclarativepathview.cpp
index 5771f84..380c6ad 100644
--- a/src/declarative/graphicsitems/qdeclarativepathview.cpp
+++ b/src/declarative/graphicsitems/qdeclarativepathview.cpp
@@ -426,7 +426,7 @@ QDeclarativePathView::~QDeclarativePathView()
The model provides a set of data that is used to create the items for the view.
For large or dynamic datasets the model is usually provided by a C++ model object.
- Models can also be created directly in XML, using the ListModel element.
+ Models can also be created directly in QML, using the ListModel element.
\sa {qmlmodels}{Data Models}
*/
@@ -650,8 +650,8 @@ void QDeclarativePathViewPrivate::setOffset(qreal o)
so as to stay with the current item.
The below example demonstrates how to make a simple highlight. Note the use
- of the PathView.onPath property to ensure that the highlight is hidden
- when flicked off of the path.
+ of the \l{PathView::onPath}{PathView.onPath} attached property to ensure that
+ the highlight is hidden when flicked away from the path.
\code
Component {
diff --git a/src/declarative/qml/qdeclarativeimageprovider.cpp b/src/declarative/qml/qdeclarativeimageprovider.cpp
index 241df87..4743a1b 100644
--- a/src/declarative/qml/qdeclarativeimageprovider.cpp
+++ b/src/declarative/qml/qdeclarativeimageprovider.cpp
@@ -59,13 +59,13 @@ public:
\list
\o Loaded using QPixmaps rather than actual image files
- \o Loaded asynchronously in a separate thread, if imageType() is \l ImageType::Image
+ \o Loaded asynchronously in a separate thread, if imageType() is \l{QDeclarativeImageProvider::ImageType}{ImageType::Image}
\endlist
To specify that an image should be loaded by an image provider, use the
\bold {"image:"} scheme for the URL source of the image, followed by the
identifiers of the image provider and the requested image. For example:
-
+
\qml
Image { source: "image://myimageprovider/image.png" }
\endqml
@@ -83,7 +83,7 @@ public:
and "red", respectively:
\snippet examples/declarative/cppextensions/imageprovider/imageprovider-example.qml 0
-
+
When these images are loaded by QML, it looks for a matching image provider
and calls its requestImage() or requestPixmap() method (depending on its
imageType()) to load the image. The method is called with the \c id
@@ -136,7 +136,7 @@ public:
main thread. In this case, if \l {Image::}{asynchronous} is set to
\c true, the value is ignored and the image is loaded
synchronously.
-
+
\sa QDeclarativeEngine::addImageProvider()
*/
diff --git a/src/declarative/qml/qdeclarativelist.h b/src/declarative/qml/qdeclarativelist.h
index 399b2a1..c10bc11 100644
--- a/src/declarative/qml/qdeclarativelist.h
+++ b/src/declarative/qml/qdeclarativelist.h
@@ -98,16 +98,16 @@ public:
private:
static void qlist_append(QDeclarativeListProperty *p, T *v) {
- ((QList<T *> *)p->data)->append(v);
+ reinterpret_cast<QList<T *> *>(p->data)->append(v);
}
static int qlist_count(QDeclarativeListProperty *p) {
- return ((QList<T *> *)p->data)->count();
+ return reinterpret_cast<QList<T *> *>(p->data)->count();
}
static T *qlist_at(QDeclarativeListProperty *p, int idx) {
- return ((QList<T *> *)p->data)->at(idx);
+ return reinterpret_cast<QList<T *> *>(p->data)->at(idx);
}
static void qlist_clear(QDeclarativeListProperty *p) {
- return ((QList<T *> *)p->data)->clear();
+ return reinterpret_cast<QList<T *> *>(p->data)->clear();
}
};
#endif
diff --git a/src/declarative/qml/qdeclarativeprivate.h b/src/declarative/qml/qdeclarativeprivate.h
index cb916bf..d45ddbc 100644
--- a/src/declarative/qml/qdeclarativeprivate.h
+++ b/src/declarative/qml/qdeclarativeprivate.h
@@ -105,7 +105,7 @@ namespace QDeclarativePrivate
template<class From, class To>
struct StaticCastSelectorClass<From, To, sizeof(int)>
{
- static inline int cast() { return (int)((intptr_t)static_cast<To *>((From *)0x10000000)) - 0x10000000; }
+ static inline int cast() { return int(reinterpret_cast<intptr_t>(static_cast<To *>(reinterpret_cast<From *>(0x10000000)))) - 0x10000000; }
};
template<class From, class To>
@@ -119,7 +119,7 @@ namespace QDeclarativePrivate
static inline int cast()
{
- return StaticCastSelectorClass<From, To, sizeof(check((From *)0))>::cast();
+ return StaticCastSelectorClass<From, To, sizeof(check(reinterpret_cast<From *>(0)))>::cast();
}
};
diff --git a/src/declarative/util/qdeclarativeanimation.cpp b/src/declarative/util/qdeclarativeanimation.cpp
index b901bb3..a747706 100644
--- a/src/declarative/util/qdeclarativeanimation.cpp
+++ b/src/declarative/util/qdeclarativeanimation.cpp
@@ -1329,7 +1329,7 @@ void QDeclarativeVector3dAnimation::setTo(QVector3D t)
\snippet doc/src/snippets/declarative/rotationanimation.qml 0
- Notice the RotationAnimation did not need to set a \l {PropertyAnimation::}{target}
+ Notice the RotationAnimation did not need to set a \l target
value. As a convenience, when used in a transition, RotationAnimation will rotate all
properties named "rotation" or "angle". You can override this by providing
your own properties via \l {PropertyAnimation::properties}{properties} or
diff --git a/src/declarative/util/qdeclarativetransition.cpp b/src/declarative/util/qdeclarativetransition.cpp
index 7042d0c..aa1426c 100644
--- a/src/declarative/util/qdeclarativetransition.cpp
+++ b/src/declarative/util/qdeclarativetransition.cpp
@@ -63,7 +63,7 @@ QT_BEGIN_NAMESPACE
to (50, 50). The added Transition specifies that when the rectangle
changes between the default and the "moved" state, any changes
to the \c x and \c y properties should be animated, using an \c Easing.InOutQuad.
-
+
\snippet doc/src/snippets/declarative/transition.qml 0
Notice the example does not require \l{PropertyAnimation::}{to} and