mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix e-book viewer not displaying cover from HTMLZ files. Fixes #1388595 [Cover not referenced in index.html file](https://bugs.launchpad.net/calibre/+bug/1388595)
This commit is contained in:
parent
44eae0780a
commit
83dc50444d
@ -116,7 +116,7 @@ class HTMLZInput(InputFormatPlugin):
|
||||
break
|
||||
if opf:
|
||||
opf = OPF(opf, basedir=os.getcwdu())
|
||||
cover_path = opf.raster_cover
|
||||
cover_path = opf.raster_cover or opf.cover
|
||||
# Set the cover.
|
||||
if cover_path:
|
||||
cdata = None
|
||||
|
@ -143,7 +143,7 @@ class EbookIterator(BookmarksMixin):
|
||||
|
||||
cover = self.opf.cover
|
||||
if cover and self.ebook_ext in {'lit', 'mobi', 'prc', 'opf', 'fb2',
|
||||
'azw', 'azw3', 'docx'}:
|
||||
'azw', 'azw3', 'docx', 'htmlz'}:
|
||||
cfile = os.path.join(self.base, 'calibre_iterator_cover.html')
|
||||
rcpath = os.path.relpath(cover, self.base).replace(os.sep, '/')
|
||||
chtml = (TITLEPAGE%prepare_string_for_xml(rcpath, True)).encode('utf-8')
|
||||
|
Loading…
x
Reference in New Issue
Block a user