Preferences/ConfigurationPages/IconsPreviewDialog.py

branch
Py2 comp.
changeset 2525
8b507a9a2d40
parent 2302
f29e9405c851
child 3058
0a02c433f52d
equal deleted inserted replaced
2523:139f182b72f6 2525:8b507a9a2d40
4 # 4 #
5 5
6 """ 6 """
7 Module implementing a dialog to preview the contents of an icon directory. 7 Module implementing a dialog to preview the contents of an icon directory.
8 """ 8 """
9
10 from __future__ import unicode_literals # __IGNORE_WARNING__
9 11
10 import os.path 12 import os.path
11 13
12 from PyQt4.QtGui import QListWidgetItem, QDialog, QIcon 14 from PyQt4.QtGui import QListWidgetItem, QDialog, QIcon
13 from PyQt4.QtCore import QDir 15 from PyQt4.QtCore import QDir
24 Constructor 26 Constructor
25 27
26 @param parent parent widget (QWidget) 28 @param parent parent widget (QWidget)
27 @param dirName name of directory to show (string) 29 @param dirName name of directory to show (string)
28 """ 30 """
29 super().__init__(parent) 31 super(IconsPreviewDialog, self).__init__(parent)
30 self.setupUi(self) 32 self.setupUi(self)
31 33
32 dir = QDir(dirName) 34 dir = QDir(dirName)
33 for icon in dir.entryList(["*.png"]): 35 for icon in dir.entryList(["*.png"]):
34 QListWidgetItem(QIcon(os.path.join(dirName, icon)), 36 QListWidgetItem(QIcon(os.path.join(dirName, icon)),

eric ide

mercurial