1
0
Fork 0
mirror of https://github.com/shlomif/PySolFC.git synced 2025-04-05 00:02:29 -04:00

Ensured icon style menu is correctly sorted.

This commit is contained in:
Joe R 2023-03-23 16:43:21 -04:00
parent 69bbec8e70
commit 0c0feeae97

View file

@ -25,7 +25,9 @@ def createToolbarMenu(menubar, menu):
tearoff = menu.cget('tearoff')
data_dir = os.path.join(menubar.app.dataloader.dir, 'images', 'toolbar')
submenu = MfxMenu(menu, label=n_('Icon Style'), tearoff=tearoff)
for f in os.listdir(data_dir):
styledirs = os.listdir(data_dir)
styledirs.sort()
for f in styledirs:
d = os.path.join(data_dir, f)
if os.path.isdir(d) and os.path.exists(os.path.join(d, 'small')):
name = f.replace('_', ' ').capitalize()