version 1.22, 2004/06/03 18:05:57
|
version 1.23, 2004/06/04 12:28:12
|
Line 491 class zogiLib(Folder):
|
Line 491 class zogiLib(Folder):
|
tag += '</div>' |
tag += '</div>' |
return tag |
return tag |
|
|
|
def createScalerDiv(self): |
|
"""generate scaler img and table with navigation arrows""" |
|
self.checkQuery() |
|
pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt/zogilib_img_div')).__of__(self) |
|
return pt() |
|
|
def createAuxDiv(self): |
def createAuxDiv(self): |
"""generate other divs""" |
"""generate other divs""" |
self.checkQuery() |
self.checkQuery() |
Line 629 class zogiLib(Folder):
|
Line 635 class zogiLib(Folder):
|
print "ZOGILIB: have to store query!!" |
print "ZOGILIB: have to store query!!" |
storeQuery(self) |
storeQuery(self) |
|
|
|
def zogilibPath(self): |
|
"""returns an URL to the zogiLib instance""" |
|
url = self.REQUEST['URL1'] |
|
url += self.basePath |
|
# should end with "/" |
|
if len(url) > 0 and url[-1] != '/': |
|
url += '/' |
|
return url |
|
|
def getDLParam(self, param): |
def getDLParam(self, param): |
"""returns parameter""" |
"""returns parameter""" |
try: |
try: |
Line 659 class zogiLib(Folder):
|
Line 674 class zogiLib(Folder):
|
|
|
def setDLParams(self,pn=None,ws=None,rot=None,brgt=None,cont=None): |
def setDLParams(self,pn=None,ws=None,rot=None,brgt=None,cont=None): |
"""setze Parameter""" |
"""setze Parameter""" |
ret="" |
|
|
|
if brgt: |
|
self.setDLParam('brgt', brgt) |
self.setDLParam('brgt', brgt) |
|
|
if cont: |
|
self.setDLParam('cont', cont) |
self.setDLParam('cont', cont) |
|
self.setDLParam('ws', ws) |
|
self.setDLParam('rot', rot) |
|
|
if pn: |
if pn: |
# unmark |
# unmark |
self.setDLParam('mk', None) |
self.setDLParam('mk', None) |
self.setDLParam('pn', pn) |
self.setDLParam('pn', pn) |
|
|
if ws: |
|
self.setDLParam('ws', ws) |
|
|
|
if rot: |
|
self.setDLParam('rot', rot) |
|
|
|
return self.display() |
return self.display() |
|
|
|
|
Line 708 class zogiLib(Folder):
|
Line 715 class zogiLib(Folder):
|
def getBiggerWS(self): |
def getBiggerWS(self): |
"""ws+1""" |
"""ws+1""" |
ws=self.getDLParam('ws') |
ws=self.getDLParam('ws') |
|
print "ws: ", ws |
if ws: |
if ws: |
|
print "WS!" |
return int(ws)+1 |
return int(ws)+1 |
else: |
else: |
return 2 |
return 2 |
Line 717 class zogiLib(Folder):
|
Line 726 class zogiLib(Folder):
|
"""ws-1""" |
"""ws-1""" |
ws=self.getDLParam('ws') |
ws=self.getDLParam('ws') |
if ws: |
if ws: |
if int(ws)==1: |
return max(int(ws)-1, 1) |
return 1 |
|
else: |
|
return int(ws)-1 |
|
else: |
else: |
return 1 |
return 1 |
|
|