diff options
author | Lars Knoll <lars.knoll@qt.io> | 2016-08-15 10:35:53 +0200 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2016-10-10 14:11:47 +0000 |
commit | 4ee2bc4e9c05d8daec8b04412a0b7c0264fbc1a4 (patch) | |
tree | 03b0dd07b6b087b5bdaded499961ee1492d408ae /src/quick/items/qquickanimatedimage.cpp | |
parent | 11e0e5574a529e337e43ab15fca357b109ea2834 (diff) |
Turn the no-network support into a configurable feature
Change-Id: Ic70f60c124fe166b37fbe9b853735be3c5e0d46d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/quick/items/qquickanimatedimage.cpp')
-rw-r--r-- | src/quick/items/qquickanimatedimage.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/quick/items/qquickanimatedimage.cpp b/src/quick/items/qquickanimatedimage.cpp index 6f14bf15fe..85251330cb 100644 --- a/src/quick/items/qquickanimatedimage.cpp +++ b/src/quick/items/qquickanimatedimage.cpp @@ -47,7 +47,7 @@ #include <QtQml/qqmlfile.h> #include <QtQml/qqmlengine.h> #include <QtGui/qmovie.h> -#ifndef QT_NO_NETWORK +#if QT_CONFIG(qml_network) #include <QtNetwork/qnetworkrequest.h> #include <QtNetwork/qnetworkreply.h> #endif @@ -146,7 +146,7 @@ QQuickAnimatedImage::QQuickAnimatedImage(QQuickItem *parent) QQuickAnimatedImage::~QQuickAnimatedImage() { Q_D(QQuickAnimatedImage); -#ifndef QT_NO_NETWORK +#if QT_CONFIG(qml_network) if (d->reply) d->reply->deleteLater(); #endif @@ -268,7 +268,7 @@ void QQuickAnimatedImage::setSource(const QUrl &url) if (url == d->url) return; -#ifndef QT_NO_NETWORK +#if QT_CONFIG(qml_network) if (d->reply) { d->reply->deleteLater(); d->reply = 0; @@ -325,7 +325,7 @@ void QQuickAnimatedImage::load() d->_movie = new QMovie(lf); movieRequestFinished(); } else { -#ifndef QT_NO_NETWORK +#if QT_CONFIG(qml_network) if (d->status != Loading) { d->status = Loading; emit statusChanged(d->status); @@ -354,7 +354,7 @@ void QQuickAnimatedImage::movieRequestFinished() Q_D(QQuickAnimatedImage); -#ifndef QT_NO_NETWORK +#if QT_CONFIG(qml_network) if (d->reply) { d->redirectCount++; if (d->redirectCount < ANIMATEDIMAGE_MAXIMUM_REDIRECT_RECURSION) { |