diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2009-12-21 13:53:29 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2009-12-21 13:53:29 +0000 |
commit | fd8e2a3deb0154e59cf4949721ab0200c6f0e99d (patch) | |
tree | 8305589e4bbdd79a4e2375144308bf9a727f85ba /xgps | |
parent | af4c85801807f5b556c1fc1fa71ceb18c35a729e (diff) | |
download | gpsd-fd8e2a3deb0154e59cf4949721ab0200c6f0e99d.tar.gz |
Make AIS display honor the selected degree format.
Diffstat (limited to 'xgps')
-rwxr-xr-x | xgps | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -161,8 +161,9 @@ class AISView: "Encapsulate store and view objects for watching AIS data." AIS_ENTRIES = 10 DWELLTIME = 360 - def __init__(self): + def __init__(self, deg_type): "Initialize the store and view." + self.deg_type = deg_type self.name_to_mmsi = {} self.named = {} self.store = gtk.ListStore(str,str,str,str,str,str) @@ -211,7 +212,7 @@ class AISView: else: latsuff = "" lat = abs(lat) - lat = gps.client.deg_to_str(gps.client.deg_dd, lat) + lat = gps.client.deg_to_str(self.deg_type, lat) if lon < 0: lonsuff = "W" elif lon > 0: @@ -394,7 +395,7 @@ class Base: aisframe = gtk.Frame(label="AIS Data") self.aisbox.add(aisframe) - self.aisview = AISView() + self.aisview = AISView(self.deg_type) aisframe.add(self.aisview.widget) self.window.show_all() |