From 1fb30ba07ce6e7893e5cd0b2ac257a43bcbc7a49 Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Wed, 8 Aug 2007 11:57:20 +0000 Subject: [PATCH] take frameAspect --- oxdbarchive/model.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/oxdbarchive/model.py b/oxdbarchive/model.py index c456e5a..4ae93c8 100644 --- a/oxdbarchive/model.py +++ b/oxdbarchive/model.py @@ -45,8 +45,9 @@ class Archive(SQLObject): def notifyFrontend(self, action, md5sum): if self.baseUrlFrontend: dto = socket.getdefaulttimeout() - socket.setdefaulttimeout(100) + socket.setdefaulttimeout(256) url = "%s/%s?md5sum=%s" % (self.baseUrlFrontend, action, md5sum) + print url result = read_url(url) #print "Frontend:", result['result'] socket.setdefaulttimeout(dto) @@ -146,7 +147,7 @@ class Archive(SQLObject): def importFrontend(self): if self.baseUrlFrontend: dto = socket.getdefaulttimeout() - socket.setdefaulttimeout(100) + socket.setdefaulttimeout(256) url = "%s/%s" % (self.baseUrlFrontend, 'list') result = read_url(url) files = simplejson.loads(result)['files'] @@ -431,7 +432,7 @@ class ArchiveFile(SQLObject): position = inpoint.replace(':', '.') flash_movie = join(self.frameFolder, '%s.%s' % (position, 'flv')) width = 128 - height = int(width / (self.width / self.height)) + height = int(width / self.frameAspect) height = height - height % 2 inpoint = inpoint.replace('.', ':') if outpoint == -1: