Merge branch 'master' of git@host.fluxility.com:optimg

This commit is contained in:
Paul Chaplin 2010-02-02 20:12:25 +00:00
commit abedbc5bdd

View file

@ -98,11 +98,11 @@ class StartQT4(QMainWindow):
oldfilesize = oldfile.size() oldfilesize = oldfile.size()
oldfilesizestr = size(oldfilesize, system=alternative) oldfilesizestr = size(oldfilesize, system=alternative)
if name.endsWith("jpg"): if path.splitext(str(filename))[1].lower() in [".jpg", ".jpeg"]:
runstr = 'jpegoptim --strip-all -f "' + str(filename) + '"' runstr = 'jpegoptim --strip-all -f "' + str(filename) + '"'
runfile = system(runstr) runfile = system(runstr)
elif name.endsWith("png"): elif path.splitext(str(filename))[1].lower() in [".png"]:
#runstr = ('optipng -force -o7 "' + str(filename) #runstr = ('optipng -force -o7 "' + str(filename)
#+ '"; advpng -z4 "' + str(filename) + '"') ## don't do advpng yet #+ '"; advpng -z4 "' + str(filename) + '"') ## don't do advpng yet
runstr = 'optipng -force -o7 "' + str(filename) + '"' runstr = 'optipng -force -o7 "' + str(filename) + '"'