add downloading items to download tab

This commit is contained in:
2025-10-12 00:50:40 +02:00
parent f358d5462f
commit 962ce8984c
3 changed files with 15 additions and 3 deletions
+9
View File
@@ -109,6 +109,15 @@ class MainWindow(QtWidgets.QMainWindow, QWidget):
self.progress_timer.timeout.connect(lambda: run_thread(threading.Thread(target=self.update_progress)))
self.progress_timer.start(1000)
self.download_timer = QTimer()
self.download_timer.timeout.connect(lambda: run_thread(threading.Thread(target=self.download_list_update)))
self.download_timer.start(5000)
def download_list_update(self):
self.downloadList.clear()
for download in state.downloads:
self.downloadList.addItem(download.name)
def closeEvent(self, event: QCloseEvent):
closehelper()
event.accept()