aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquickanimatedimage_p_p.h
diff options
context:
space:
mode:
authorTobias Koenig <tobias.koenig@kdab.com>2016-04-27 08:12:12 +0200
committerTobias Koenig <tobias.koenig@kdab.com>2016-05-02 06:49:54 +0000
commitbe031102c226ab9bccc1e73018af25082240bcc3 (patch)
tree1d7a271174527b9dbb48e2bda5d72510f45e0221 /src/quick/items/qquickanimatedimage_p_p.h
parent1650377af7dfb01a0641d4e21bf1ba33e6a7320f (diff)
AnimatedImage: Fix value of sourceSize property
Cache the source size of the internal QMovie object during the change of the 'source' property to ensure that always a valid source size is returned without emitting more sourceSizeChanged() signals than necessary. Change-Id: I637b80efb133197b7345b09fcf8a7bb80c5643c9 Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
Diffstat (limited to 'src/quick/items/qquickanimatedimage_p_p.h')
-rw-r--r--src/quick/items/qquickanimatedimage_p_p.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/quick/items/qquickanimatedimage_p_p.h b/src/quick/items/qquickanimatedimage_p_p.h
index bb921fda4a..ed1bf368c8 100644
--- a/src/quick/items/qquickanimatedimage_p_p.h
+++ b/src/quick/items/qquickanimatedimage_p_p.h
@@ -60,7 +60,7 @@ class QQuickAnimatedImagePrivate : public QQuickImagePrivate
public:
QQuickAnimatedImagePrivate()
- : playing(true), paused(false), preset_currentframe(0), _movie(0), reply(0), redirectCount(0), oldPlaying(false)
+ : playing(true), paused(false), preset_currentframe(0), _movie(0), reply(0), redirectCount(0), oldPlaying(false), currentSourceSize(0, 0)
{
}
@@ -74,6 +74,7 @@ public:
int redirectCount;
bool oldPlaying;
QMap<int, QQuickPixmap *> frameMap;
+ QSize currentSourceSize;
};
QT_END_NAMESPACE