fix: setting null icons

This commit is contained in:
Vinicius Moreira
2019-07-30 11:09:40 -03:00
parent e8dfbbc448
commit 1c5c0766a3
2 changed files with 8 additions and 1 deletions

View File

@@ -7,6 +7,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## [0.4.3]
### Improvements
- new environment variable / argument to enable / disable the tray icon and update-check daemon: FPAKMAN_TRAY (--tray)
### Fixes:
- replacing default app icons by null icons
## [0.4.2] - 2019-07-28
### Improvements

View File

@@ -179,9 +179,14 @@ class AppsTable(QTableWidget):
icon_was_cached = True
if not icon_data:
icon_bytes = http_response.readAll()
if not icon_bytes:
return
icon_was_cached = False
pixmap = QPixmap()
icon_bytes = http_response.readAll()
pixmap.loadFromData(icon_bytes)
icon = QIcon(pixmap)
icon_data = {'icon': icon, 'bytes': icon_bytes}