summaryrefslogtreecommitdiffstats
path: root/module/DownloadThread.py
diff options
context:
space:
mode:
Diffstat (limited to 'module/DownloadThread.py')
-rw-r--r--module/DownloadThread.py11
1 files changed, 8 insertions, 3 deletions
diff --git a/module/DownloadThread.py b/module/DownloadThread.py
index 95ed88da0..2178bd21e 100644
--- a/module/DownloadThread.py
+++ b/module/DownloadThread.py
@@ -121,16 +121,21 @@ class DownloadThread(Thread):
def handleNewInterface(self, pyfile):
status = pyfile.status
plugin = pyfile.plugin
- status.type = "starting"
- self.parent.parent.pullManager.addEvent(UpdateEvent("file", pyfile.id, "queue"))
if plugin.__type__ == "container" or plugin.__type__ == "crypter":
status.type = "decrypting"
+ else: #hoster
+ status.type = "starting"
self.parent.parent.pullManager.addEvent(UpdateEvent("file", pyfile.id, "queue"))
if plugin.__type__ == "container":
plugin.decrypt(pyfile.url)
-
+ else:
+ plugin.preparePlugin(self)
+
+ plugin.prepareDownload()
+
+ plugin.startDownload()
status.type = "finished"
def download(self, pyfile):