changeset 108:d89e41ecf522

arnica_slides: rotate only the image and purge webnail and thumbnail. Both will be recreated from the arnica parser.
author Reimar Bauer <rb.proj AT googlemail DOT com>
date Thu, 26 Jun 2008 15:48:27 +0200
parents 0ea5b9461351
children dba6f45c448e
files data/plugin/action/arnica_slides.py
diffstat 1 files changed, 2 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/data/plugin/action/arnica_slides.py	Thu Jun 26 14:37:18 2008 +0200
+++ b/data/plugin/action/arnica_slides.py	Thu Jun 26 15:48:27 2008 +0200
@@ -78,21 +78,14 @@
     @param angle: the angle to rotate to
     @param img_type: type of image PNG or JPEG
     """
-    # image
+    # image needs to be rotated only, webnail and thumbnail removed 
+    # both will be recreated from the parser call
     image_object = Image.open(file_name)
     os.remove(file_name)
     image_object.rotate(angle).save(file_name, img_type)
 
-    # image becomes webnail
-    new_image_object = Image.open(file_name)
-    new_image_object.thumbnail((640, 640), Image.ANTIALIAS)
     os.remove(webf)
-    new_image_object.save(webf, img_type)
-
-    # image becomes thumbnail based on webnail
-    new_image_object.thumbnail((128, 128), Image.ANTIALIAS)
     os.remove(thumbf)
-    new_image_object.save(thumbf, img_type)
 
 def html_js(request, counter):
     """ javscript for the slides