Geography : I finaly catch this problem : autozoom the first time we click on the map.
svn: r19461
This commit is contained in:
@ -647,9 +647,9 @@ class GeoGraphyView(OsmGps, NavigationView):
|
|||||||
config.get("geography.zoom") )
|
config.get("geography.zoom") )
|
||||||
else:
|
else:
|
||||||
self._autozoom()
|
self._autozoom()
|
||||||
self.end_selection = None
|
|
||||||
self.save_center(self.latit, self.longt)
|
self.save_center(self.latit, self.longt)
|
||||||
config.set("geography.zoom", self.osm.props.zoom)
|
config.set("geography.zoom", self.osm.props.zoom)
|
||||||
|
self.end_selection = None
|
||||||
|
|
||||||
def _get_father_and_mother_name(self, event):
|
def _get_father_and_mother_name(self, event):
|
||||||
"""
|
"""
|
||||||
|
@ -119,9 +119,9 @@ class LifeWayLayer(gobject.GObject, osmgpsmap.GpsMapLayer):
|
|||||||
ctx.set_line_join(cairo.LINE_JOIN_ROUND)
|
ctx.set_line_join(cairo.LINE_JOIN_ROUND)
|
||||||
ctx.set_line_width(3)
|
ctx.set_line_width(3)
|
||||||
color = gtk.gdk.color_parse(lifeway[1])
|
color = gtk.gdk.color_parse(lifeway[1])
|
||||||
ctx.set_source_rgba(color.red / 65535,
|
ctx.set_source_rgba(color.red / 255,
|
||||||
color.green / 65535,
|
color.green / 255,
|
||||||
color.blue / 65535,
|
color.blue / 255,
|
||||||
0.1) # transparency
|
0.1) # transparency
|
||||||
ggc = drawable.new_gc()
|
ggc = drawable.new_gc()
|
||||||
rds = float(lifeway[2])
|
rds = float(lifeway[2])
|
||||||
@ -163,9 +163,9 @@ class LifeWayLayer(gobject.GObject, osmgpsmap.GpsMapLayer):
|
|||||||
coord_x, coord_y = gpsmap.convert_geographic_to_screen(conv_pt)
|
coord_x, coord_y = gpsmap.convert_geographic_to_screen(conv_pt)
|
||||||
map_points.append((coord_x, coord_y))
|
map_points.append((coord_x, coord_y))
|
||||||
color = gtk.gdk.color_parse(lifeway[1])
|
color = gtk.gdk.color_parse(lifeway[1])
|
||||||
ctx.set_source_rgb(color.red / 65535,
|
ctx.set_source_rgb(color.red / 255,
|
||||||
color.green / 65535,
|
color.green / 255,
|
||||||
color.blue / 65535)
|
color.blue / 255)
|
||||||
first = True
|
first = True
|
||||||
for idx_pt in range(0, len(map_points)):
|
for idx_pt in range(0, len(map_points)):
|
||||||
if first:
|
if first:
|
||||||
|
Reference in New Issue
Block a user