diff data/plugin/parser/text_x_arnica.py @ 43:623ddf996af2

text_x_arnica: album after creating of all thumbnails and webnails
author Reimar Bauer <rb.proj AT googlemail DOT com>
date Tue, 03 Jun 2008 08:44:51 +0200
parents 7bf792c8364b
children 769a97fcdcbe
line wrap: on
line diff
--- a/data/plugin/parser/text_x_arnica.py	Tue Jun 03 00:12:49 2008 +0200
+++ b/data/plugin/parser/text_x_arnica.py	Tue Jun 03 08:44:51 2008 +0200
@@ -629,42 +629,44 @@
         for dummy in range(COLUMNS):
             data.columns.extend([Column('', label=(''))])
 
-        # initialize colums of output table
+        col_count = 1
+        result = []
+        for image in self.full:
+            i = self.full.index(image)
+            self.create_thumbnail_and_webnail(image, self.web[i], self.thumb[i], self.imgtype[i])
+            if self.album == '0':
+                if self.image_for_webnail == '1':
+                    self.webimg = self.full
+                else:
+                    self.webimg = self.web
 
-        col_count = 1
+                if self.mode == '1':
+                    text = self.mode1_html(i)
+
+                if self.mode == '2':
+                    text = self.mode2_html(i)
+
+                if col_count <= COLUMNS:
+                    result.append(''.join(text))
+
+                if col_count == COLUMNS and self.album == '0':
+                    col_count = 0
+                    data.addRow(tuple(result))
+                    result = []
+
+                col_count += 1
 
         if self.album == '1':
             front_image = self.front_image or self.full[0]
             i = self.full.index(front_image)
-
-        result = []
-        for image in self.full:
-            i = self.full.index(image)
             self.create_thumbnail_and_webnail(image, self.web[i], self.thumb[i], self.imgtype[i])
-
             if self.image_for_webnail == '1':
                 self.webimg = self.full
             else:
                 self.webimg = self.web
 
-            if self.mode == '1':
-                text = self.mode1_html(i)
-
-            if self.mode == '2':
-                text = self.mode2_html(i)
-
-            if col_count <= COLUMNS:
-                result.append(''.join(text))
-
-            if self.album == '1':
-                break
-
-            if col_count == COLUMNS:
-                col_count = 0
-                data.addRow(tuple(result))
-                result = []
-
-            col_count += 1
+            text = self.mode1_html(i)
+            result.append(''.join(text))
 
         if result:
             data.addRow(tuple(result))