From b59631db5f348c2cba069ffc725251afc87a3a1c Mon Sep 17 00:00:00 2001 From: Sengian Date: Sun, 24 Oct 2010 23:26:17 +0200 Subject: [PATCH] Add a get cover option which overwrite the cover if one is available to metadata_single.py but needs to be modified to remember the option --- src/calibre/gui2/dialogs/fetch_metadata.ui | 11 +++++++++-- src/calibre/gui2/dialogs/metadata_single.py | 2 ++ 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/src/calibre/gui2/dialogs/fetch_metadata.ui b/src/calibre/gui2/dialogs/fetch_metadata.ui index c54ee66044..0b39089ee3 100644 --- a/src/calibre/gui2/dialogs/fetch_metadata.ui +++ b/src/calibre/gui2/dialogs/fetch_metadata.ui @@ -109,6 +109,13 @@ + + + + Overwrite author and title with author and title of selected book + + + @@ -117,9 +124,9 @@ - + - Overwrite author and title with author and title of selected book + Overwrite cover image with downloaded cover if available for the selected book diff --git a/src/calibre/gui2/dialogs/metadata_single.py b/src/calibre/gui2/dialogs/metadata_single.py index ef1bddca0c..65cfdf57d4 100644 --- a/src/calibre/gui2/dialogs/metadata_single.py +++ b/src/calibre/gui2/dialogs/metadata_single.py @@ -709,6 +709,8 @@ class MetadataSingleDialog(ResizableDialog, Ui_MetadataSingleDialog): self.title.setText(book.title) self.authors.setText(authors_to_string(book.authors)) if book.author_sort: self.author_sort.setText(book.author_sort) + if d.opt_overwrite_cover_image.isChecked() and book.has_cover: + self.fetch_cover() if book.publisher: self.publisher.setEditText(book.publisher) if book.isbn: self.isbn.setText(book.isbn) if book.pubdate: