513 |
|
|
514 |
OsmGpsMap *map = OSM_GPS_MAP(context->widget); |
OsmGpsMap *map = OSM_GPS_MAP(context->widget); |
515 |
|
|
516 |
|
puts("press event"); |
517 |
|
|
518 |
/* check if we actually clicked parts of the OSD */ |
/* check if we actually clicked parts of the OSD */ |
519 |
if(osm_gps_map_osd_check(map, event->x, event->y) != OSD_NONE) |
if(osm_gps_map_osd_check(map, event->x, event->y) != OSD_NONE) |
520 |
return FALSE; |
return FALSE; |
783 |
GdkEventButton *event, map_context_t *context) { |
GdkEventButton *event, map_context_t *context) { |
784 |
OsmGpsMap *map = OSM_GPS_MAP(context->widget); |
OsmGpsMap *map = OSM_GPS_MAP(context->widget); |
785 |
|
|
786 |
|
puts("release event"); |
787 |
|
|
788 |
/* in "MAP_CACHE" state only one cache is visible */ |
/* in "MAP_CACHE" state only one cache is visible */ |
789 |
/* and the map is in navigation mode. the balloon is */ |
/* and the map is in navigation mode. the balloon is */ |
790 |
/* pretty useless there */ |
/* pretty useless there */ |
829 |
g_object_get(map, "zoom", &zoom, NULL); |
g_object_get(map, "zoom", &zoom, NULL); |
830 |
context->appdata->map.zoom = zoom; |
context->appdata->map.zoom = zoom; |
831 |
|
|
832 |
|
gboolean dpix; |
833 |
|
g_object_get(map, "double-pixel", &dpix, NULL); |
834 |
|
context->appdata->map.dpix = dpix; |
835 |
|
|
836 |
gfloat lat, lon; |
gfloat lat, lon; |
837 |
g_object_get(map, "latitude", &lat, "longitude", &lon, NULL); |
g_object_get(map, "latitude", &lat, "longitude", &lon, NULL); |
838 |
context->appdata->map.pos.lat = lat; |
context->appdata->map.pos.lat = lat; |
986 |
"auto-center", FALSE, |
"auto-center", FALSE, |
987 |
"record-trip-history", FALSE, |
"record-trip-history", FALSE, |
988 |
"show-trip-history", FALSE, |
"show-trip-history", FALSE, |
989 |
|
"double-pixel", context->appdata->map.dpix, |
990 |
proxy?"proxy-uri":NULL, proxy, |
proxy?"proxy-uri":NULL, proxy, |
991 |
NULL); |
NULL); |
992 |
|
|