From bfc6b9c637f00f3cb222be3a652cbd80c294a153 Mon Sep 17 00:00:00 2001 From: Sanj Date: Wed, 6 Jul 2011 18:22:17 +0530 Subject: [PATCH] nonsense commit --- edgware/editor/models.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/edgware/editor/models.py b/edgware/editor/models.py index 2e70a6f..1a4cdd4 100644 --- a/edgware/editor/models.py +++ b/edgware/editor/models.py @@ -88,9 +88,9 @@ class Product(models.Model): def get_print_multiplier(self, dpi): # product = Product.objects.get(pk=self.product.id) print_width_mm = self.typ.print_width - dpm = dpi // 25.4 + dpm = dpi / 25.4 pixel_width = print_width_mm * dpm - m = pixel_width // 800.0 + m = pixel_width / 800.0 return m def get_page_list(self): @@ -105,7 +105,7 @@ class Product(models.Model): aspect_ratio = self.typ.aspect_ratio width = width + .0 height = int(round(width / aspect_ratio)) - return (int(width), height,) + return (int(round(width)), height,) class Video(models.Model): fil = models.ForeignKey(File)