From 16282bce65901d7a86c26e8ca5f0e74bc81e8eff Mon Sep 17 00:00:00 2001 From: "Rob G. Healey" Date: Sat, 10 Dec 2011 20:29:10 +0000 Subject: [PATCH] Minor change to OSM maps in PlacePage and FamilyMap. svn: r18568 --- src/plugins/lib/libhtmlconst.py | 2 +- src/plugins/webreport/NarrativeWeb.py | 13 +++++++------ 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/plugins/lib/libhtmlconst.py b/src/plugins/lib/libhtmlconst.py index 2f23edefe..dcf670e5b 100644 --- a/src/plugins/lib/libhtmlconst.py +++ b/src/plugins/lib/libhtmlconst.py @@ -120,7 +120,7 @@ _COPY_OPTIONS = [ ] # NarrativeWeb javascript code for PlacePage's "Open Street Map"... -openstreet_jsc = """ +openstreetmap_jsc = """ OpenLayers.Lang.setCode("%s"); map = new OpenLayers.Map("place_canvas"); diff --git a/src/plugins/webreport/NarrativeWeb.py b/src/plugins/webreport/NarrativeWeb.py index 300b3697f..32139ae50 100644 --- a/src/plugins/webreport/NarrativeWeb.py +++ b/src/plugins/webreport/NarrativeWeb.py @@ -96,7 +96,7 @@ import gen.mime from gen.display.name import displayer as _nd from DateHandler import displayer as _dd from gen.proxy import PrivateProxyDb, LivingProxyDb -from libhtmlconst import _CHARACTER_SETS, _CC, _COPY_OPTIONS, openstreet_jsc, google_jsc +from libhtmlconst import _CHARACTER_SETS, _CC, _COPY_OPTIONS, openstreetmap_jsc, google_jsc # import HTML Class from src/plugins/lib/libhtml.py from libhtml import Html @@ -3324,7 +3324,7 @@ class PlacePage(BasePage): jsc += google_jsc % (latitude, longitude) else: # do not need to write on head, load into canvas - jsc += openstreet_jsc % (Utils.xml_lang()[3:5].lower(), longitude, latitude) + jsc += openstreetmap_jsc % (Utils.xml_lang()[3:5].lower(), longitude, latitude) # there is no need to add an ending "", # as it will be added automatically! @@ -5000,7 +5000,7 @@ class IndividualPage(BasePage): if self.mapservice == "Google": jsc += google_jsc % (latitude, longitude) else: - jsc += openstreetmap_jsc % (latitude, longitude) + jsc += openstreetmap_jsc % (Utils.xml_lang()[3:5].lower(), longitude, latitude) # number of markers > 1 else: @@ -5058,7 +5058,7 @@ class IndividualPage(BasePage): var vectorLayer = new OpenLayers.Layer.Vector("Overlay");""" % (Utils.xml_lang()[3:5].lower(), midY_, midX_, zoomlevel) - for (latitude, longitude, pname, h, d) in place_lat_long: + for (latitude, longitude, pname, h, d, etype) in place_lat_long: jsc += """ var feature = new OpenLayers.Feature.Vector( new OpenLayers.Geometry.Point( %s, %s ).transform(epsg4326, projectTo), @@ -5097,10 +5097,11 @@ class IndividualPage(BasePage): with Html("div", class_ ="content", id ="FamilyMapDetail") as mapdetail: body += mapdetail + # add page title mapdetail += Html("h3", html_escape("Tracking %s" % self.get_name(person)), inline=True) - # page message + # page description msg = _("This map page represents the person and their descendants with " "all of their event/ places. If you place your mouse over " "the marker it will display the place name. The markers and the Reference " @@ -5149,7 +5150,7 @@ class IndividualPage(BasePage): tbody += trow trow.extend( - Html("td", data, class_ =colclass) + Html("td", data, class_ =colclass, inline =True) for data, colclass in [ (self.place_link(handle, placetitle, up =True), "ColumnName"), (date, "ColumnDate"),