diff options
author | mkaay <mkaay@mkaay.de> | 2010-02-01 18:54:19 +0100 |
---|---|---|
committer | mkaay <mkaay@mkaay.de> | 2010-02-01 18:54:19 +0100 |
commit | 5d04894e73a52e69968cb4a4bfd9a581cd2fb86c (patch) | |
tree | 648c782dd85d3905f1162b4914a87262f92487be /module/download_thread.py | |
parent | clean + strip (diff) | |
download | pyload-5d04894e73a52e69968cb4a4bfd9a581cd2fb86c.tar.xz |
new update system for remote clients
Diffstat (limited to 'module/download_thread.py')
-rw-r--r-- | module/download_thread.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/module/download_thread.py b/module/download_thread.py index 4a031a04c..65c7e1e23 100644 --- a/module/download_thread.py +++ b/module/download_thread.py @@ -23,6 +23,7 @@ from os.path import join from time import sleep, time from module.network.Request import AbortDownload +from module.PullEvents import UpdateEvent class Status(object): """ Saves all status information @@ -116,6 +117,7 @@ class Download_Thread(threading.Thread): self.loadedPyFile.status.error = str(e) finally: self.parent.job_finished(self.loadedPyFile) + self.parent.parent.pullManager.addEvent(UpdateEvent("file", self.loadedPyFile.id, "queue")) else: sleep(3) sleep(0.8) @@ -126,6 +128,7 @@ class Download_Thread(threading.Thread): def download(self, pyfile): status = pyfile.status status.type = "starting" + self.parent.parent.pullManager.addEvent(UpdateEvent("file", pyfile.id, "queue")) pyfile.init_download() @@ -136,6 +139,7 @@ class Download_Thread(threading.Thread): status.type = "decrypting" else: status.type = "downloading" + self.parent.parent.pullManager.addEvent(UpdateEvent("file", pyfile.id, "queue")) location = join(pyfile.folder, status.filename) pyfile.plugin.proceed(status.url, location) |