#include "khmaps.h"
-static DownloadOptions khmaps_options = { NULL, 0 };
+static DownloadOptions khmaps_options = { NULL, 0, a_check_map_file };
void khmaps_init () {
VikMapsLayer_MapType map_type = { 8, 256, 256, VIK_VIEWPORT_DRAWMODE_KH, khmaps_coord_to_mapcoord, khmaps_mapcoord_to_center_coord, khmaps_download };
return buf;
}
-void khmaps_download ( MapCoord *src, const gchar *dest_fn )
+int khmaps_download ( MapCoord *src, const gchar *dest_fn )
{
gchar *tmp = kh_encode(src->x, src->y, src->scale);
gchar *uri = g_strdup_printf ( "/kh?v=2&t=%s", tmp );
g_free ( tmp );
a_http_download_get_url ( "kh.google.com", uri, dest_fn, &khmaps_options );
g_free ( uri );
+ return 1;
}
/* Popularity has its disadvantages ... */