From 35751efad585f51055fb82bfd1b607c56e11415f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Jastrz=C4=99bski?= Date: Fri, 28 Jun 2013 00:08:36 +0200 Subject: [PATCH] Little tweaks --- kcc/KCC_gui.py | 2 +- kcc/comic2ebook.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/kcc/KCC_gui.py b/kcc/KCC_gui.py index 561681b..6d9b3d5 100644 --- a/kcc/KCC_gui.py +++ b/kcc/KCC_gui.py @@ -138,8 +138,8 @@ class WorkerThread(QtCore.QThread): self.emit(QtCore.SIGNAL("hideProgressBar")) except UserWarning as warn: self.errors = True - self.emit(QtCore.SIGNAL("addMessage"), 'KCC failed to create output file!', 'warning') self.emit(QtCore.SIGNAL("addMessage"), str(warn), 'warning') + self.emit(QtCore.SIGNAL("addMessage"), 'KCC failed to create output file!', 'warning') except Exception as err: self.errors = True type_, value_, traceback_ = sys.exc_info() diff --git a/kcc/comic2ebook.py b/kcc/comic2ebook.py index c0eae5c..137e4a5 100755 --- a/kcc/comic2ebook.py +++ b/kcc/comic2ebook.py @@ -340,7 +340,7 @@ def applyImgOptimization(img, isSplit, toRight, options, overrideQuality=5): img.quantizeImage() -def dirImgProcess(path, origPath): +def dirImgProcess(path): global options, splitCount work = [] pagenumber = 0 @@ -381,7 +381,7 @@ def dirImgProcess(path, origPath): pagenumbermodifier += 1 else: rmtree(path) - raise UserWarning("Empty directory: " + origPath) + raise UserWarning("Source directory is empty.") def fileImgProcess_init(queue, options): @@ -742,7 +742,7 @@ def main(argv=None, qtGUI=None): print "Processing images..." if GUI: GUI.emit(QtCore.SIGNAL("progressBarTick"), 'status', 'Processing images') - dirImgProcess(path + "/OEBPS/Images/", args[0]) + dirImgProcess(path + "/OEBPS/Images/") if GUI: GUI.emit(QtCore.SIGNAL("progressBarTick"), 1) if options.cbzoutput: