From cb3817e6f460066b8abae0d6e804d091c6e8db48 Mon Sep 17 00:00:00 2001 From: Benny Malengier Date: Mon, 26 Jan 2009 21:26:20 +0000 Subject: [PATCH] polish geoview svn: r11736 --- src/DataViews/GeoView.py | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/DataViews/GeoView.py b/src/DataViews/GeoView.py index e6fd9d8c9..ea29dcf1d 100644 --- a/src/DataViews/GeoView.py +++ b/src/DataViews/GeoView.py @@ -295,8 +295,8 @@ class HtmlView(PageView.PageView): with an embedded webbrowser showing a given URL """ - def __init__(self, dbstate, uistate): - PageView.PageView.__init__(self, _('HtmlView'), dbstate, uistate) + def __init__(self, dbstate, uistate, title=_('HtmlView')): + PageView.PageView.__init__(self, title, dbstate, uistate) self.dbstate = dbstate @@ -512,13 +512,19 @@ class HtmlView(PageView.PageView): class GeoView(HtmlView): def __init__(self,dbstate,uistate): - HtmlView.__init__(self, dbstate, uistate) + HtmlView.__init__(self, dbstate, uistate, title=_('GeoView')) self.usedmap = "openstreetmap" self.displaytype = "person" self.nbmarkers = 0 self.nbpages = 0 + def top_widget(self): + """ + The top widget to use, for GeoView, none + """ + return gtk.Label() + def on_delete(self): """ We need to suppress temporary files here. @@ -967,6 +973,8 @@ class GeoView(HtmlView): # We center the map on a point at the center of all markers self.centerlat = maxlat/2 self.centerlon = maxlong/2 + latit = self.centerlat + longt = self.centerlon for mark in self.sort: cent = int(mark[6]) if cent: