From e237c46108b4686a3d26fe082295d1bf0b042f0b Mon Sep 17 00:00:00 2001 From: tmzullinger Date: Tue, 31 Jul 2007 20:42:54 +0000 Subject: merge changes from the bug-1723660 branch git-svn-id: https://gtkpod.svn.sf.net/svnroot/gtkpod/libgpod/trunk@1662 f01d2545-417e-4e96-918e-98f8d0dbbcb6 --- bindings/python/examples/save_photos.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'bindings/python/examples/save_photos.py') diff --git a/bindings/python/examples/save_photos.py b/bindings/python/examples/save_photos.py index abf23ed..ec8079b 100755 --- a/bindings/python/examples/save_photos.py +++ b/bindings/python/examples/save_photos.py @@ -24,6 +24,10 @@ import gpod +if not hasattr(gpod.Thumbnail, 'get_pixbuf'): + print 'Sorry, gpod was built without pixbuf support.' + raise SystemExit + photodb = gpod.PhotoDatabase("/mnt/ipod") print photodb @@ -34,6 +38,6 @@ for album in photodb.PhotoAlbums: for thumbnail, n in zip(photo.thumbnails, range(0,len(photo.thumbnails))): print " ", thumbnail - thumbnail.save_image("/tmp/%d-%d.png" % (photo['id'],n)) + thumbnail.get_pixbuf().save("/tmp/%d-%d.png" % (photo['id'],n),"png") photodb.close() -- cgit