summaryrefslogtreecommitdiff
path: root/silx/gui/icons.py
diff options
context:
space:
mode:
authorPicca Frédéric-Emmanuel <picca@synchrotron-soleil.fr>2019-05-28 08:16:16 +0200
committerPicca Frédéric-Emmanuel <picca@synchrotron-soleil.fr>2019-05-28 08:16:16 +0200
commita763e5d1b3921b3194f3d4e94ab9de3fbe08bbdd (patch)
tree45d462ed36a5522e9f3b9fde6c4ec4918c2ae8e3 /silx/gui/icons.py
parentcebdc9244c019224846cb8d2668080fe386a6adc (diff)
New upstream version 0.10.1+dfsg
Diffstat (limited to 'silx/gui/icons.py')
-rw-r--r--silx/gui/icons.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/silx/gui/icons.py b/silx/gui/icons.py
index ef99591..1493b92 100644
--- a/silx/gui/icons.py
+++ b/silx/gui/icons.py
@@ -29,7 +29,7 @@ Use :func:`getQIcon` to create Qt QIcon from the name identifying an icon.
__authors__ = ["T. Vincent"]
__license__ = "MIT"
-__date__ = "05/10/2018"
+__date__ = "07/01/2019"
import os
@@ -213,11 +213,12 @@ class MultiImageAnimatedIcon(AbstractAnimatedIcon):
self.__frames = []
for i in range(100):
try:
- filename = getQFile("%s/%02d" % (filename, i))
+ frame_filename = os.sep.join((filename, ("%02d" %i)))
+ frame_file = getQFile(frame_filename)
except ValueError:
break
try:
- icon = qt.QIcon(filename.fileName())
+ icon = qt.QIcon(frame_file.fileName())
except ValueError:
break
self.__frames.append(icon)
@@ -420,4 +421,5 @@ def getQFile(name):
qfile = qt.QFile(filename)
if qfile.exists():
return qfile
+ _logger.debug("File '%s' not found.", filename)
raise ValueError('Not an icon name: %s' % name)