summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGavin Hurlbut <ghurlbut@mythtv.org>2010-11-20 06:21:11 (GMT)
committer Gavin Hurlbut <ghurlbut@mythtv.org>2010-11-20 06:21:11 (GMT)
commite8c6c19862ca9b96159a85e2c30158298325888a (patch)
tree7aecff905093592be153f22d9aa3203d6582d0e7
parentda47d2ebe9be563055ba829b5adf2d6ff4c16af3 (diff)
Backport [27302] from trunk
Fixes non-animated GIF reloading in MythUIImage git-svn-id: http://svn.mythtv.org/svn/branches/release-0-24-fixes@27303 7dbf422c-18fa-0310-86e9-fd20926502f2
-rw-r--r--mythtv/libs/libmythui/mythuiimage.cpp16
1 files changed, 14 insertions, 2 deletions
diff --git a/mythtv/libs/libmythui/mythuiimage.cpp b/mythtv/libs/libmythui/mythuiimage.cpp
index a87b935..c3c3667 100644
--- a/mythtv/libs/libmythui/mythuiimage.cpp
+++ b/mythtv/libs/libmythui/mythuiimage.cpp
@@ -210,6 +210,12 @@ void MythUIImage::Clear(void)
m_Images.remove(it.key());
}
m_Delays.clear();
+ if (m_animatedImage)
+ {
+ m_LowNum = 0;
+ m_HighNum = 0;
+ m_animatedImage = false;
+ }
}
/**
@@ -221,7 +227,12 @@ void MythUIImage::Reset(void)
if (m_Filename != m_OrigFilename)
{
m_Filename = m_OrigFilename;
- m_animatedImage = false;
+ if (m_animatedImage)
+ {
+ m_LowNum = 0;
+ m_HighNum = 0;
+ m_animatedImage = false;
+ }
d->m_UpdateLock.unlock();
Load();
}
@@ -626,7 +637,8 @@ bool MythUIImage::Load(bool allowLoadInBackground, bool forceStat)
int j = 0;
for (int i = m_LowNum; i <= m_HighNum && !m_animatedImage; i++)
{
- if (!m_animatedImage && m_HighNum >= 1)
+ if (!m_animatedImage && m_HighNum != m_LowNum &&
+ bFilename.contains("%1"))
filename = bFilename.arg(i);
imagelabel = GenImageLabel(filename, w, h);