mirror of
https://github.com/spalencsar/bearhub.git
synced 2026-07-09 09:54:14 +02:00
[view] improvement: always displaying the 'any file filter' (*) as the last option for file chooser components
This commit is contained in:
@@ -858,7 +858,13 @@ class FormQt(QGroupBox):
|
||||
|
||||
def open_chooser(e):
|
||||
if c.allowed_extensions:
|
||||
exts = ';;'.join({'*.{}'.format(e) for e in c.allowed_extensions})
|
||||
sorted_exts = [e for e in c.allowed_extensions if e != '*']
|
||||
sorted_exts.sort()
|
||||
|
||||
if '*' in c.allowed_extensions:
|
||||
sorted_exts.append('*')
|
||||
|
||||
exts = ';;'.join({f'*.{e}' for e in sorted_exts})
|
||||
else:
|
||||
exts = '{} (*);;'.format(self.i18n['all_files'].capitalize())
|
||||
|
||||
|
||||
Reference in New Issue
Block a user