mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
7071bdee82
commit
716d55e869
@ -11,6 +11,7 @@ import sys, shutil, os
|
|||||||
from threading import Thread
|
from threading import Thread
|
||||||
from glob import glob
|
from glob import glob
|
||||||
|
|
||||||
|
import sip
|
||||||
from PyQt4.Qt import (QDialog, QApplication, QLabel, QGridLayout,
|
from PyQt4.Qt import (QDialog, QApplication, QLabel, QGridLayout,
|
||||||
QDialogButtonBox, Qt, pyqtSignal, QListWidget,
|
QDialogButtonBox, Qt, pyqtSignal, QListWidget,
|
||||||
QListWidgetItem, QSize, QIcon)
|
QListWidgetItem, QSize, QIcon)
|
||||||
@ -76,7 +77,7 @@ class PDFCovers(QDialog):
|
|||||||
page_images(self.pdfpath, self.tdir, last=10)
|
page_images(self.pdfpath, self.tdir, last=10)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
self.error = as_unicode(e)
|
self.error = as_unicode(e)
|
||||||
if self.isVisible():
|
if not sip.isdeleted(self) and self.isVisible():
|
||||||
self.rendering_done.emit()
|
self.rendering_done.emit()
|
||||||
|
|
||||||
def show_pages(self):
|
def show_pages(self):
|
||||||
|
@ -322,7 +322,7 @@ class MetadataSingleDialogBase(ResizableDialog):
|
|||||||
pdfpath = self.formats_manager.get_format_path(self.db, self.book_id,
|
pdfpath = self.formats_manager.get_format_path(self.db, self.book_id,
|
||||||
'pdf')
|
'pdf')
|
||||||
from calibre.gui2.metadata.pdf_covers import PDFCovers
|
from calibre.gui2.metadata.pdf_covers import PDFCovers
|
||||||
d = self.__pdf_covers = PDFCovers(pdfpath, parent=self)
|
d = PDFCovers(pdfpath, parent=self)
|
||||||
if d.exec_() == d.Accepted:
|
if d.exec_() == d.Accepted:
|
||||||
cpath = d.cover_path
|
cpath = d.cover_path
|
||||||
if cpath:
|
if cpath:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user