Browse Source

Protect against nullicons

master
Nils 4 years ago
parent
commit
af070e1e89
  1. 2
      engine/findicons.py
  2. 2
      qtgui/mainwindow.py

2
engine/findicons.py

@ -152,7 +152,7 @@ if __name__ == "__main__":
print(SEARCH_DIRECTORIES) print(SEARCH_DIRECTORIES)
print() print()
for exe in ("ZynAddSubFx", "patroneo", "jack_mixer", "carla", "ardour6", "synthv1"): for exe in ("zynaddsubfx", "patroneo", "jack_mixer", "carla", "ardour6", "synthv1"):
r = findIconPath(exe) r = findIconPath(exe)
if r: if r:
print (f"{exe} Best resolution: {r[0]}") print (f"{exe} Best resolution: {r[0]}")

2
qtgui/mainwindow.py

@ -261,7 +261,7 @@ class MainWindow(QtWidgets.QMainWindow):
for entry in programs: for entry in programs:
exe = entry["argodejoExec"] exe = entry["argodejoExec"]
if "argodejoIconPath" in entry: if "argodejoIconPath" in entry and entry["argodejoIconPath"]: #not null
icon = QtGui.QIcon(entry["argodejoIconPath"]) icon = QtGui.QIcon(entry["argodejoIconPath"])
assert not icon.isNull() assert not icon.isNull()
else: else:

Loading…
Cancel
Save