Merge pull request #163 from ankitest/patch-7

Install addons by spaced list; showInfo -> tooltip
This commit is contained in:
Damien Elmes 2017-02-15 15:37:20 +10:00 committed by GitHub
commit f483753b6c

View file

@ -165,10 +165,12 @@ class GetAddons(QDialog):
def accept(self): def accept(self):
QDialog.accept(self) QDialog.accept(self)
# create downloader thread # create downloader thread
ret = download(self.mw, self.form.code.text()) txt = self.form.code.text().split()
for x in txt:
ret = download(self.mw, x)
if not ret: if not ret:
return return
data, fname = ret data, fname = ret
self.mw.addonManager.install(data, fname) self.mw.addonManager.install(data, fname)
self.mw.progress.finish() self.mw.progress.finish()
showInfo(_("Download successful. Please restart Anki.")) tooltip(_("Download successful. Please restart Anki."), period=3000)