Store: ebook download, More shortening work.

This commit is contained in:
John Schember 2011-09-20 20:37:41 -04:00
parent d0c500703d
commit a628dce0f1

View File

@ -15,6 +15,7 @@ from PyQt4.QtWebKit import QWebView, QWebPage
from calibre import USER_AGENT, get_proxies, get_download_filename
from calibre.ebooks import BOOK_EXTENSIONS
from calibre.ptempfile import PersistentTemporaryFile
from calibre.utils.filenames import ascii_filename
class NPWebView(QWebView):
@ -67,6 +68,7 @@ class NPWebView(QWebView):
filename = get_download_filename(url, cf)
ext = os.path.splitext(filename)[1][1:].lower()
filename = ascii_filename(filename[:60] + '.' + ext)
if ext not in BOOK_EXTENSIONS:
if ext == 'acsm':
from calibre.gui2.dialogs.confirm_delete import confirm