diff options
author | David Boddie <david.boddie@nokia.com> | 2011-06-17 11:59:47 (GMT) |
---|---|---|
committer | David Boddie <david.boddie@nokia.com> | 2011-06-17 11:59:47 (GMT) |
commit | fa4c5540bd0fd9f8bb7238c1d947f0763b8607e1 (patch) | |
tree | 10453eeb3d8c000e38a27d6d1344886de1e79736 /src/declarative/qml | |
parent | fc2a790e96be47b4da3e308c5e0272e4840a2618 (diff) | |
parent | c390312f8fbea14ac4df0c5185ca814054f448d8 (diff) | |
download | Qt-fa4c5540bd0fd9f8bb7238c1d947f0763b8607e1.zip Qt-fa4c5540bd0fd9f8bb7238c1d947f0763b8607e1.tar.gz Qt-fa4c5540bd0fd9f8bb7238c1d947f0763b8607e1.tar.bz2 |
Merge branch '4.8' of scm.dev.nokia.troll.no:qt/qt into 4.8
Diffstat (limited to 'src/declarative/qml')
-rw-r--r-- | src/declarative/qml/qdeclarativeengine.cpp | 3 | ||||
-rw-r--r-- | src/declarative/qml/qdeclarativeimageprovider.cpp | 14 |
2 files changed, 13 insertions, 4 deletions
diff --git a/src/declarative/qml/qdeclarativeengine.cpp b/src/declarative/qml/qdeclarativeengine.cpp index e5e89d4..8679445 100644 --- a/src/declarative/qml/qdeclarativeengine.cpp +++ b/src/declarative/qml/qdeclarativeengine.cpp @@ -771,9 +771,6 @@ QNetworkAccessManager *QDeclarativeEngine::networkAccessManager() const All required image providers should be added to the engine before any QML sources files are loaded. - Note that images loaded from a QDeclarativeImageProvider are cached - by QPixmapCache, similar to any image loaded by QML. - \sa removeImageProvider() */ void QDeclarativeEngine::addImageProvider(const QString &providerId, QDeclarativeImageProvider *provider) diff --git a/src/declarative/qml/qdeclarativeimageprovider.cpp b/src/declarative/qml/qdeclarativeimageprovider.cpp index 559adf4..fa88c00 100644 --- a/src/declarative/qml/qdeclarativeimageprovider.cpp +++ b/src/declarative/qml/qdeclarativeimageprovider.cpp @@ -136,7 +136,8 @@ public: Image providers that support QImage loading automatically include support for asychronous loading of images. To enable asynchronous loading for an - \l Image source, set \l Image::asynchronous to \c true. When this is enabled, + image source, set the \c asynchronous property to \c true for the relevant + \l Image, \l BorderImage or \l AnimatedImage object. When this is enabled, the image request to the provider is run in a low priority thread, allowing image loading to be executed in the background, and reducing the performance impact on the user interface. @@ -147,6 +148,17 @@ public: \c true, the value is ignored and the image is loaded synchronously. + + \section2 Image caching + + Images returned by a QDeclarativeImageProvider are automatically cached, + similar to any image loaded by the QML engine. When an image with a + "image://" prefix is loaded from cache, requestImage() and requestPixmap() + will not be called for the relevant image provider. If an image should always + be fetched from the image provider, and should not be cached at all, set the + \c cache property to \c false for the relevant \l Image, \l BorderImage or + \l AnimatedImage object. + \sa QDeclarativeEngine::addImageProvider() */ |