Ejemplo n.º 1
0
 def add_coords(self):
     pt = Point()
     try:
         if not self.fd['latmin']:
             self.fd['latmin'] = 0
         pt.set_lat(self.fd['latdeg'], self.fd['latmin'], self.fd['dirlat'])
     except (InvalidPointError, ValueError) as point_err:
         self.err['lat'] = str(point_err)
     try:
         if not self.fd['lonmin']:
             self.fd['lonmin'] = 0
         pt.set_lon(self.fd['londeg'], self.fd['lonmin'], self.fd['dirlon'])
     except (InvalidPointError, ValueError) as point_err:
         self.err['lon'] = str(point_err)
     self.wpt.position = ndb.GeoPt(pt.lat, pt.lon)
Ejemplo n.º 2
0
 def add_coords(self):
     pt = Point()
     try:
         if not self.fd['latmin']:
             self.fd['latmin'] = 0
         pt.set_lat(self.fd['latdeg'], self.fd['latmin'], self.fd['dirlat'])
     except (InvalidPointError, ValueError) as point_err:
         self.err['lat'] = str(point_err)
     try:
         if not self.fd['lonmin']:
             self.fd['lonmin'] = 0
         pt.set_lon(self.fd['londeg'], self.fd['lonmin'], self.fd['dirlon'])
     except (InvalidPointError, ValueError) as point_err:
         self.err['lon'] = str(point_err)
     self.wpt.position = ndb.GeoPt(pt.lat, pt.lon)
Ejemplo n.º 3
0
 def human_readable_lon(self):
     return Point.human_readable_lon(self.position.lon)
Ejemplo n.º 4
0
 def human_readable_lat(self):
     return Point.human_readable_lat(self.position.lat)
Ejemplo n.º 5
0
 def human_readable_lon(self):
     return Point.human_readable_lon(self.position.lon)
Ejemplo n.º 6
0
 def human_readable_lat(self):
     return Point.human_readable_lat(self.position.lat)
Ejemplo n.º 7
0
 def __init__(self):
     self.centre = Point()
     self.zoom = self.DEFAULT_ZOOM
     self.type = "HYBRID"