--- ECHO_content/ECHO_collection.py 2004/05/10 08:44:19 1.73
+++ ECHO_content/ECHO_collection.py 2004/05/10 13:23:59 1.74
@@ -989,14 +989,52 @@ class ECHO_collection(Folder, Persistent
return ret
def createJSAreas(self):
- """CreateJava"""
+ """new version of createJavaScript"""
dynamical="\n"
for ob in self.getGraphicCoords():
- if ob[5] == "area":
+ if ob[5] == "area":
dynamical+="""addArea('%s', 'overview', %s, 'area');\n"""%(ob[1],ob[0])
else:
dynamical+="""addArea('%s', 'overview', %s, 'arrow');\n"""%(ob[1],ob[0])
return dynamical
+
+ def createMapHead(self):
+ """generate divs"""
+ pt=PageTemplateFile(os.path.join(package_home(globals()), 'zpt/ECHO_content_map_frag_js')).__of__(self)
+ return pt()
+
+ def createMapLink(self, ob, text=None):
+ """generate map link"""
+ id = ob[1]
+ link = ob[1]
+ if text == None:
+ text = ob[2]
+ tag = '" + text + ""
+ return tag
+
+ def createMapAux(self, ob, arrowsrc="http://nausikaa2.rz-berlin.mpg.de/digitallibrary/servlet/Scaler/?dw=15&fn=icons/pfeil"):
+ """generate map link image, text and other stuff"""
+ id = ob[1]
+ link = ob[1]
+ vtype = ob[5]
+ ctype = ob[3].contentType
+
+ tag = ''%(id,id,id,link)
+ if vtype == "view point":
+ rot = ob[4][4]
+ tag += ''%(id,arrowsrc,rot)
+ else:
+ tag += ''
+ tag += ''
+ return tag
+
security.declarePublic('getCreditObject')
def getCreditObject(self,name):
@@ -1224,7 +1262,6 @@ class ECHO_collection(Folder, Persistent
sendFile(self, 'js/js_lib.js', 'text/plain')
return
-
def getGraphicCoords(self):
"""Give list of coordinates"""
subColTypes=['ECHO_collection','ECHO_resource']