mirror of
https://github.com/ankitects/anki.git
synced 2025-11-11 15:17:12 -05:00
add progress to check (media) db, fix call
This commit is contained in:
parent
42052e6349
commit
9fa640feca
1 changed files with 6 additions and 3 deletions
|
|
@ -1005,7 +1005,9 @@ On the next sync, all cards will be sent to the server. \
|
||||||
Any changes on the server since your last sync will be lost.<br><br>
|
Any changes on the server since your last sync will be lost.<br><br>
|
||||||
<b>This operation is not undoable.</b> Proceed?""")):
|
<b>This operation is not undoable.</b> Proceed?""")):
|
||||||
return
|
return
|
||||||
|
self.progress.start(immediate=True)
|
||||||
ret = self.deck.fixIntegrity()
|
ret = self.deck.fixIntegrity()
|
||||||
|
self.progress.finish()
|
||||||
showText(ret)
|
showText(ret)
|
||||||
self.reset()
|
self.reset()
|
||||||
return ret
|
return ret
|
||||||
|
|
@ -1015,8 +1017,7 @@ Any changes on the server since your last sync will be lost.<br><br>
|
||||||
mb.setWindowTitle(_("Anki"))
|
mb.setWindowTitle(_("Anki"))
|
||||||
mb.setIcon(QMessageBox.Warning)
|
mb.setIcon(QMessageBox.Warning)
|
||||||
mb.setText(_("""\
|
mb.setText(_("""\
|
||||||
This operation looks through the content of your cards for media, and \
|
This operation finds media that is missing or unused.
|
||||||
registers it so that it can be used with the online and mobile clients.
|
|
||||||
|
|
||||||
If you choose Scan+Delete, any media in your media folder that is not \
|
If you choose Scan+Delete, any media in your media folder that is not \
|
||||||
used by cards will be deleted. Please note that media is only \
|
used by cards will be deleted. Please note that media is only \
|
||||||
|
|
@ -1037,7 +1038,9 @@ doubt."""))
|
||||||
delete = True
|
delete = True
|
||||||
else:
|
else:
|
||||||
return
|
return
|
||||||
(nohave, unused) = rebuildMediaDir(self.deck, delete=delete)
|
self.progress.start(immediate=True)
|
||||||
|
(nohave, unused) = self.deck.media.check(delete)
|
||||||
|
self.progress.finish()
|
||||||
# generate report
|
# generate report
|
||||||
report = ""
|
report = ""
|
||||||
if nohave:
|
if nohave:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue