mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
bcabbd88d1
commit
53c5ff5daa
@ -132,14 +132,17 @@ class EditMetadataAction(InterfaceAction):
|
|||||||
if all_failed:
|
if all_failed:
|
||||||
num = len(failed_ids | failed_covers)
|
num = len(failed_ids | failed_covers)
|
||||||
self.cleanup_bulk_download(tdir)
|
self.cleanup_bulk_download(tdir)
|
||||||
return error_dialog(self.gui, _('Download failed'),
|
return error_dialog(self.gui, _('Download failed'), ngettext(
|
||||||
_('Failed to download metadata or covers for any of the %d'
|
'Failed to download metadata or cover for the selected book',
|
||||||
' book(s).') % num, det_msg=det_msg, show=True)
|
'Failed to download metadata or covers for any of the {} books.', num
|
||||||
|
).format(num), det_msg=det_msg, show=True)
|
||||||
|
|
||||||
self.gui.status_bar.show_message(_('Metadata download completed'), 3000)
|
self.gui.status_bar.show_message(_('Metadata download completed'), 3000)
|
||||||
|
|
||||||
msg = '<p>' + _('Finished downloading metadata for <b>%d book(s)</b>. '
|
msg = '<p>' + ngettext(
|
||||||
'Proceed with updating the metadata in your library?')%len(id_map)
|
'Finished downloading metadata for the selected book.',
|
||||||
|
'Finished downloading metadata for <b>{} books</b>.', len(id_map)).format(len(id_map)) + ' ' + \
|
||||||
|
_('Proceed with updating the metadata in your library?')
|
||||||
|
|
||||||
show_copy_button = False
|
show_copy_button = False
|
||||||
checkbox_msg = None
|
checkbox_msg = None
|
||||||
|
@ -136,7 +136,9 @@ def start_download(gui, ids, callback, ensure_fields=None):
|
|||||||
tf.close()
|
tf.close()
|
||||||
|
|
||||||
job = Job('metadata bulk download',
|
job = Job('metadata bulk download',
|
||||||
_('Download metadata for %d books')%len(ids),
|
ngettext(
|
||||||
|
'Download metadata for one book',
|
||||||
|
'Download metadata for {} books', len(ids)).format(len(ids)),
|
||||||
download, (ids, tf.name, gui.current_db, d.identify, d.covers,
|
download, (ids, tf.name, gui.current_db, d.identify, d.covers,
|
||||||
ensure_fields), {}, callback)
|
ensure_fields), {}, callback)
|
||||||
job.metadata_and_covers = (d.identify, d.covers)
|
job.metadata_and_covers = (d.identify, d.covers)
|
||||||
@ -275,5 +277,3 @@ def download(all_ids, tf, db, do_identify, covers, ensure_fields,
|
|||||||
lm_map, all_failed)
|
lm_map, all_failed)
|
||||||
finally:
|
finally:
|
||||||
notifier.keep_going = False
|
notifier.keep_going = False
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user