dont show gifs in dialog

This commit is contained in:
Kilian Valkhof 2010-02-02 14:57:31 +01:00
parent 3ec1938b3e
commit 9d126924e7
2 changed files with 14 additions and 14 deletions

20
todo
View file

@ -20,14 +20,12 @@ trimage: simple gui for:
optipng for png and gif, jpegoptim for jpeg. both are available in ubuntu as dependencies (our primary platform) optipng for png and gif, jpegoptim for jpeg. both are available in ubuntu as dependencies (our primary platform)
^ no gif. optipng optimized gif by converting to png ^ no gif. optipng optimized gif by converting to png
========================================== ==========================================
todo app wise todo app wise
- implement something for gifs (or not)
- implement drag and drop on table - implement drag and drop on table
- clean up code, make it PEP-8 - clean up code, make it PEP-8
- figure out what to do with: - implement threading (and include advpng then)
- recompress and optipng ( o7? ) not really doing anything
- lockup when opening files (i'd like it to not lock up the file dialog)
todo else todo else
- figure out dependencies for a .deb/how to make a .deb - figure out dependencies for a .deb/how to make a .deb
@ -35,10 +33,16 @@ todo else
- figure out how to make mac and win versions - figure out how to make mac and win versions
current dependencies: current dependencies:
python python 2.6
python-qt4 python-qt4 4.4
hurry.filesize (bundled) hurry.filesize (bundled)
optipng optipng 0.6.2.1
jpgegoptim jpgegoptim 1.2.2
===========================================
1.5:
later versions:
pnypng api? http://www.gracepointafterfive.com/punypng/api
imagemagick/graphicmagick?

View file

@ -33,7 +33,7 @@ class StartQT4(QMainWindow):
images = fd.getOpenFileNames(self, images = fd.getOpenFileNames(self,
"Select one or more image files to compress", "Select one or more image files to compress",
"", # directory "", # directory
"Image files (*.png *.gif *.jpg)") "Image files (*.png *.jpg)")
for image in images: for image in images:
self.compress_file(image) self.compress_file(image)
@ -65,10 +65,6 @@ class StartQT4(QMainWindow):
runstr = 'optipng -force -o7 "' + str(filename) + '"' runstr = 'optipng -force -o7 "' + str(filename) + '"'
runfile = system(runstr) runfile = system(runstr)
else:
print "run something for gif"
runfile = system('ls')
if runfile == 0: if runfile == 0:
newfile = QFile(filename) newfile = QFile(filename)
newfilesize = newfile.size() newfilesize = newfile.size()
@ -81,7 +77,7 @@ class StartQT4(QMainWindow):
self.update_table() self.update_table()
else: else:
print "uh. not good" #implement, something went wrong print "uh. not good" #throw dialogbox error or something?
def update_table(self): def update_table(self):