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

This commit is contained in:
Sengian 2010-10-24 23:26:17 +02:00
parent 0c26c521c2
commit b59631db5f
2 changed files with 11 additions and 2 deletions

View File

@ -109,6 +109,13 @@
</layout> </layout>
</widget> </widget>
</item> </item>
<item>
<widget class="QCheckBox" name="opt_overwrite_author_title_metadata">
<property name="text">
<string>Overwrite author and title with author and title of selected book</string>
</property>
</widget>
</item>
<item> <item>
<widget class="QCheckBox" name="opt_get_social_metadata"> <widget class="QCheckBox" name="opt_get_social_metadata">
<property name="text"> <property name="text">
@ -117,9 +124,9 @@
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QCheckBox" name="opt_overwrite_author_title_metadata"> <widget class="QCheckBox" name="opt_overwrite_cover_image">
<property name="text"> <property name="text">
<string>Overwrite author and title with author and title of selected book</string> <string>Overwrite cover image with downloaded cover if available for the selected book</string>
</property> </property>
</widget> </widget>
</item> </item>

View File

@ -709,6 +709,8 @@ class MetadataSingleDialog(ResizableDialog, Ui_MetadataSingleDialog):
self.title.setText(book.title) self.title.setText(book.title)
self.authors.setText(authors_to_string(book.authors)) self.authors.setText(authors_to_string(book.authors))
if book.author_sort: self.author_sort.setText(book.author_sort) 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.publisher: self.publisher.setEditText(book.publisher)
if book.isbn: self.isbn.setText(book.isbn) if book.isbn: self.isbn.setText(book.isbn)
if book.pubdate: if book.pubdate: