1
0
mirror of https://github.com/ciromattia/kcc synced 2026-01-27 23:47:41 +00:00
This commit is contained in:
Paweł Jastrzębski
2014-11-21 22:46:43 +01:00
parent 5ae72bf06d
commit bc0a52b848
2 changed files with 12 additions and 12 deletions

View File

@@ -111,15 +111,15 @@ class WebServerHandler(BaseHTTPRequestHandler):
self.send_header('Content-type', 'text/html')
self.end_headers()
self.wfile.write(bytes('<!DOCTYPE html>\n'
'<html lang="en">\n'
'<head><meta charset="utf-8">\n'
'<link href="' + GUI.webContent.favicon + '" rel="icon" type="image/x-icon" />\n'
'<title>Kindle Comic Converter</title>\n'
'</head>\n'
'<body>\n'
'<div style="text-align: center; font-size:25px">\n'
'<p style="font-size:50px">- <img style="vertical-align: middle" '
'alt="KCC Logo" src="' + GUI.webContent.logo + '" /> -</p>\n', 'UTF-8'))
'<html lang="en">\n'
'<head><meta charset="utf-8">\n'
'<link href="' + GUI.webContent.favicon + '" rel="icon" type="image/x-icon" />\n'
'<title>Kindle Comic Converter</title>\n'
'</head>\n'
'<body>\n'
'<div style="text-align: center; font-size:25px">\n'
'<p style="font-size:50px">- <img style="vertical-align: middle" '
'alt="KCC Logo" src="' + GUI.webContent.logo + '" /> -</p>\n', 'UTF-8'))
if len(GUI.completedWork) > 0 and not GUI.conversionAlive:
for key in sorted(GUI.completedWork.keys()):
self.wfile.write(bytes('<p><a href="' + key + '">' + key.split('.')[0] + '</a></p>\n', 'UTF-8'))
@@ -127,8 +127,8 @@ class WebServerHandler(BaseHTTPRequestHandler):
self.wfile.write(bytes('<p style="font-weight: bold">No downloads are available.<br/>'
'Convert some files and refresh this page.</p>\n', 'UTF-8'))
self.wfile.write(bytes('</div>\n'
'</body>\n'
'</html>\n', 'UTF-8'))
'</body>\n'
'</html>\n', 'UTF-8'))
elif sendReply:
outputFile = GUI.completedWork[unquote(self.path[1:])]
fp = open(outputFile, 'rb')

View File

@@ -420,7 +420,7 @@ def buildEPUB(path, chapterNames, tomeNumber):
chapter = False
for afile in filenames:
filename = getImageFileName(afile)
if not '-kcc-hq' in filename[0]:
if '-kcc-hq' not in filename[0]:
filelist.append(buildHTML(dirpath, afile, os.path.join(dirpath, afile)))
if not chapter:
chapterlist.append((dirpath.replace('Images', 'Text'), filelist[-1][1]))