Merge branch 'master' of github.com:osmandapp/Osmand
|
@ -341,19 +341,39 @@ public class GeoPointParserUtil {
|
|||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(dlat, dlon, z));
|
||||
|
||||
// http://www.google.com/maps/?q=loc:34,-106&z=11
|
||||
url = "http://www.google.com/maps/?q=loc:" + ilat + "," + ilon + "&z=" + z;
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(ilat, ilon, z));
|
||||
|
||||
// http://www.google.com/maps/?q=loc:34.99393,-106.61568&z=11
|
||||
url = "http://www.google.com/maps/?q=loc:" + dlat + "," + dlon + "&z=" + z;
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(dlat, dlon, z));
|
||||
|
||||
// https://www.google.com/maps/preview#!q=paris&data=!4m15!2m14!1m13!1s0x47e66e1f06e2b70f%3A0x40b82c3688c9460!3m8!1m3!1d24383582!2d-95.677068!3d37.0625!3m2!1i1222!2i718!4f13.1!4m2!3d48.856614!4d2.3522219
|
||||
url = "https://www.google.com/maps/preview#!q=paris&data=!4m15!2m14!1m13!1s0x47e66e1f06e2b70f%3A0x40b82c3688c9460!3m8!1m3!1d24383582!2d-95.677068!3d37.0625!3m2!1i1222!2i718!4f13.1!4m2!3d48.856614!4d2.3522219";
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint("paris"));
|
||||
|
||||
// TODO this URL does not work, where is it used?
|
||||
// http://maps.google.com/maps/q=loc:34,-106&z=11
|
||||
url = "http://maps.google.com/maps/q=loc:" + ilat + "," + ilon + "&z=" + z;
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(ilat, ilon, z));
|
||||
|
||||
// TODO this URL does not work, where is it used?
|
||||
// http://maps.google.com/maps/q=loc:34.99393,-106.61568&z=11
|
||||
url = "http://maps.google.com/maps/q=loc:" + dlat + "," + dlon + "&z=" + z;
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(dlat, dlon, z));
|
||||
|
||||
|
||||
// TODO this URL does not work, where is it used?
|
||||
// whatsapp
|
||||
// http://maps.google.com/maps/q=loc:34,-106 (You)
|
||||
z = GeoParsedPoint.NO_ZOOM;
|
||||
|
@ -362,6 +382,7 @@ public class GeoPointParserUtil {
|
|||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(ilat, ilon, z));
|
||||
|
||||
// TODO this URL does not work, where is it used?
|
||||
// whatsapp
|
||||
// http://maps.google.com/maps/q=loc:34.99393,-106.61568 (You)
|
||||
z = GeoParsedPoint.NO_ZOOM;
|
||||
|
@ -424,6 +445,27 @@ public class GeoPointParserUtil {
|
|||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(dlat, dlon, z));
|
||||
|
||||
// http://maps.google.co.uk/?q=34.99393,-106.61568
|
||||
z = GeoParsedPoint.NO_ZOOM;
|
||||
url = "http://maps.google.co.uk/?q=" + dlat + "," + dlon;
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(dlat, dlon, z));
|
||||
|
||||
// http://www.google.com.tr/maps?q=34.99393,-106.61568
|
||||
z = GeoParsedPoint.NO_ZOOM;
|
||||
url = "http://www.google.com.tr/maps?q=" + dlat + "," + dlon;
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(dlat, dlon, z));
|
||||
|
||||
// https://www.google.com/maps/place/34%C2%B059'38.1%22N+106%C2%B036'56.5%22W/@34.99393,-106.61568,17z/data=!3m1!4b1!4m2!3m1!1s0x0:0x0
|
||||
z = 17;
|
||||
url = "https://www.google.com/maps/place/34%C2%B059'38.1%22N+106%C2%B036'56.5%22W/@" + dlat + "," + dlon + "," + z + "z/data=!3m1!4b1!4m2!3m1!1s0x0:0x0";
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
assertGeoPoint(actual, new GeoParsedPoint(dlat, dlon, z));
|
||||
|
||||
// http://www.google.com/maps/place/760+West+Genesee+Street+Syracuse+NY+13204
|
||||
qstr = "760 West Genesee Street Syracuse NY 13204";
|
||||
url = "http://www.google.com/maps/place/" + URLEncoder.encode(qstr);
|
||||
|
@ -579,21 +621,6 @@ public class GeoPointParserUtil {
|
|||
System.out.println("Properly parsed as: " + actual.getGeoUriString());
|
||||
}
|
||||
|
||||
// http://www.google.com/maps/?q=loc:34,-106&z=11
|
||||
url = "http://www.google.com/maps/?q=loc:" + ilat + "," + ilon + "&z=" + z;
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
// FIXME FAIL
|
||||
assertGeoPoint(actual, new GeoParsedPoint(ilat, ilon, z));
|
||||
|
||||
// http://www.google.com/maps/?q=loc:34.99393,-106.61568&z=11
|
||||
url = "http://www.google.com/maps/?q=loc:" + dlat + "," + dlon + "&z=" + z;
|
||||
System.out.println("url: " + url);
|
||||
actual = GeoPointParserUtil.parse(url);
|
||||
// FIXME FAIL
|
||||
assertGeoPoint(actual, new GeoParsedPoint(dlat, dlon, z));
|
||||
|
||||
|
||||
// these URLs are not parsable, but should not crash or cause problems
|
||||
String[] unparsableUrls = {
|
||||
"http://maps.yandex.ru/-/CVCw6M9g",
|
||||
|
@ -784,7 +811,7 @@ public class GeoPointParserUtil {
|
|||
simpleDomains.add("www.openstreetmap.de");
|
||||
|
||||
|
||||
final Pattern commaSeparatedPairPattern = Pattern.compile("([+-]?\\d+(?:\\.\\d+)?),([+-]?\\d+(?:\\.\\d+)?)");
|
||||
final Pattern commaSeparatedPairPattern = Pattern.compile("(?:loc:)?([+-]?\\d+(?:\\.\\d+)?),([+-]?\\d+(?:\\.\\d+)?)");
|
||||
|
||||
try {
|
||||
if (host.equals("osm.org") || host.endsWith("openstreetmap.org")) {
|
||||
|
@ -861,8 +888,30 @@ public class GeoPointParserUtil {
|
|||
return new GeoParsedPoint(matcher.group(1), matcher.group(2), z, params.get("text"));
|
||||
}
|
||||
}
|
||||
} else if (host.matches("(?:www\\.)?(?:maps\\.)?google\\.[a-z]+")) {
|
||||
} else if (host.matches("(?:www\\.)?(?:maps\\.)?google\\.[a-z.]+")) {
|
||||
String latString = null;
|
||||
String lonString = null;
|
||||
String z = String.valueOf(GeoParsedPoint.NO_ZOOM);
|
||||
Map<String, String> params = getQueryParameters(uri);
|
||||
if(params.containsKey("q")){
|
||||
Matcher matcher = commaSeparatedPairPattern.matcher(params.get("q"));
|
||||
if (matcher.matches()) {
|
||||
latString = matcher.group(1);
|
||||
lonString = matcher.group(2);
|
||||
}
|
||||
} else if(params.containsKey("ll")){
|
||||
Matcher matcher = commaSeparatedPairPattern.matcher(params.get("ll"));
|
||||
if (matcher.matches()) {
|
||||
latString = matcher.group(1);
|
||||
lonString = matcher.group(2);
|
||||
}
|
||||
}
|
||||
if (latString != null && lonString != null) {
|
||||
if (params.containsKey("z")) {
|
||||
z = params.get("z");
|
||||
}
|
||||
return new GeoParsedPoint(latString, lonString, z);
|
||||
}
|
||||
if(params.containsKey("daddr")){
|
||||
return parseGoogleMapsPath(params.get("daddr"), params);
|
||||
} else if(params.containsKey("saddr")){
|
||||
|
@ -870,6 +919,13 @@ public class GeoPointParserUtil {
|
|||
} else if(params.containsKey("q")){
|
||||
return parseGoogleMapsPath(params.get("q"), params);
|
||||
}
|
||||
if (fragment != null) {
|
||||
Pattern p = Pattern.compile(".*[!&]q=([^&!]+).*");
|
||||
Matcher m = p.matcher(fragment);
|
||||
if (m.matches()) {
|
||||
return new GeoParsedPoint(m.group(1));
|
||||
}
|
||||
}
|
||||
|
||||
String[] pathPrefixes = new String[] { "/@", "/ll=",
|
||||
"loc:", "/" };
|
||||
|
|
Before Width: | Height: | Size: 2.3 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 912 B After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 387 B After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 2.7 KiB After Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 2.8 KiB After Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.1 KiB |
BIN
OsmAnd/res/drawable-mdpi/ic_action_max_speed.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
OsmAnd/res/drawable-mdpi/ic_action_next_turn.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 225 B After Width: | Height: | Size: 1 KiB |
BIN
OsmAnd/res/drawable-mdpi/ic_flat_list_dark.png
Normal file
After Width: | Height: | Size: 1 KiB |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.5 KiB |
BIN
OsmAnd/res/drawable-mdpi/ic_sort_waypoint_dark.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
OsmAnd/res/drawable-mdpi/ic_tree_list_dark.png
Normal file
After Width: | Height: | Size: 1 KiB |
BIN
OsmAnd/res/drawable-xhdpi/ic_action_max_speed.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
OsmAnd/res/drawable-xhdpi/ic_action_next_turn.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 435 B After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 3.6 KiB After Width: | Height: | Size: 2.2 KiB |
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 3.8 KiB After Width: | Height: | Size: 2 KiB |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.1 KiB |
BIN
OsmAnd/res/drawable-xxhdpi/ic_action_max_speed.png
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
OsmAnd/res/drawable-xxhdpi/ic_action_next_turn.png
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
OsmAnd/res/drawable-xxhdpi/ic_action_plus_dark.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.1 KiB |
BIN
OsmAnd/res/drawable-xxhdpi/ic_motorcycle.png
Normal file
After Width: | Height: | Size: 3.1 KiB |
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 2.3 KiB |
BIN
OsmAnd/res/drawable-xxhdpi/ic_sail_boat.png
Normal file
After Width: | Height: | Size: 2.5 KiB |
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.1 KiB |
|
@ -140,7 +140,7 @@
|
|||
<string name="map_version_changed_info">Les fichiers de cartes sur le serveur sont incompatibles avec votre version de l\'application. Pour les télécharger et les utiliser, installez une version plus récente de votre application.</string>
|
||||
<string name="shared_string_rename">Renommer</string>
|
||||
|
||||
<string name="poi_filter_nominatim">Nominatim en ligne</string>
|
||||
<string name="poi_filter_nominatim">Recherche OSM Nominatim (en ligne)</string>
|
||||
<string name="search_position_current_location_search">Recherche de la position…</string>
|
||||
<string name="search_position_current_location_found">Position trouvée</string>
|
||||
<string name="search_position_address">Adresse…</string>
|
||||
|
@ -558,7 +558,7 @@
|
|||
<string name="search_nothing_found">Rien n\'a été trouvé</string>
|
||||
<string name="searching">Recherche en cours…</string>
|
||||
<string name="searching_address">Recherche de l\'adresse…</string>
|
||||
<string name="search_osm_nominatim">Recherche de l\'adresse via OSM Nominatim</string>
|
||||
<string name="search_osm_nominatim">Recherche avec le service web OSM Nominatim</string>
|
||||
<string name="hint_search_online">Recherche en ligne : Numéro, rue, ville</string>
|
||||
<string name="search_offline_address">Hors-ligne</string>
|
||||
<string name="search_online_address">Internet</string>
|
||||
|
|
|
@ -93,7 +93,7 @@
|
|||
<string name="init_native_library">Inizializzazione libreria nativa…</string>
|
||||
<string name="choose_auto_follow_route">Centra automaticamente la mappa</string>
|
||||
<string name="choose_auto_follow_route_descr">Scegli intervallo di tempo per seguire automaticamente la posizione attuale</string>
|
||||
<string name="auto_follow_route_never">Mai (tap sulla freccia blu per avviare la navigazione manualmente)</string>
|
||||
<string name="auto_follow_route_never">Mai (tap \'Vai\' per avviare la navigazione manualmente)</string>
|
||||
<string name="auto_follow_route_navigation">Centra automaticamente solo in navigazione</string>
|
||||
<string name="auto_follow_route_navigation_descr">Centra automaticamente la visione della mappa solo durante la navigazione.</string>
|
||||
<string name="auto_follow_location_enabled">Visualizzazione mappa centrata automaticamente.</string>
|
||||
|
@ -1489,7 +1489,7 @@ Afghanistan, Albania, Algeria, Andorra, Angola, Anguilla, Antigua and Barbuda, A
|
|||
<string name="announce_gpx_waypoints">Annuncia i punti GPX di passaggio</string>
|
||||
|
||||
|
||||
<string name="driving_region_descr">Scegliete la regione di guida: USA, Europa, UK, Asia o altre</string>
|
||||
<string name="driving_region_descr">Scegliete la regione di guida: USA, Europa, UK, Asia o Altre</string>
|
||||
<string name="driving_region">Regione di guida</string>
|
||||
<string name="driving_region_japan">Giappone</string>
|
||||
<string name="driving_region_us">Stati Uniti</string>
|
||||
|
@ -2025,7 +2025,7 @@ Si consiglia di aggiungere uno o più punti intermedi per migliorarne le prestaz
|
|||
<string name="rendering_attr_pisteGrooming_name">Batti pista</string>
|
||||
<string name="free">"Libera %1$s "</string>
|
||||
<string name="device_memory">Memoria dispositivo</string>
|
||||
<string name="rendering_attr_pisteRoutes_name">Percorsi su pista</string>
|
||||
<string name="rendering_attr_pisteRoutes_name">Discese sciistiche</string>
|
||||
<string name="roads_only">Solo strade</string>
|
||||
<string name="watch">Guarda</string>
|
||||
<string name="notes">Note</string>
|
||||
|
@ -2129,7 +2129,7 @@ Si consiglia di aggiungere uno o più punti intermedi per migliorarne le prestaz
|
|||
<string name="simulate_your_location">Posizione fittizia</string>
|
||||
<string name="drawer">Solo lista</string>
|
||||
<string name="short_location_on_map">Lat %1$s\n Lon %2$s</string>
|
||||
<string name="tips_and_tricks_descr">"Domande frequenti, ultimi cambiamenti e altro"</string>
|
||||
<string name="tips_and_tricks_descr">Domande frequenti, ultimi cambiamenti e altro</string>
|
||||
<string name="routing_settings_2">Impostazioni di navigazione</string>
|
||||
<string name="general_settings_2">Impostazioni generali</string>
|
||||
<string name="shared_string_clear_all">Cancella tutto</string>
|
||||
|
@ -2144,11 +2144,11 @@ Si consiglia di aggiungere uno o più punti intermedi per migliorarne le prestaz
|
|||
<string name="action_modify">Azione modifica</string>
|
||||
<string name="action_delete">Azione elimina</string>
|
||||
<string name="osm_edits">Modifiche OSM</string>
|
||||
<string name="osmand_parking_hour">h</string><string name="osmand_parking_minute">min</string><string name="osmand_parking_time_left">Mancano</string> <string name="parking_place_limited">Parcheggio a tempo limitato a</string>
|
||||
<string name="osmand_parking_hour">h</string><string name="osmand_parking_minute">min</string><string name="osmand_parking_time_left">mancano</string> <string name="parking_place_limited">Parcheggio a tempo limitato a</string>
|
||||
<string name="your_edits">Le tue modifiche</string>
|
||||
<string name="osmand_parking_overdue">obsoleto</string>
|
||||
<string name="delay_to_start_navigation_descr">Specifica il tempo di permanenza nella schermata di pianificazione dell\'itinerario</string>
|
||||
<string name="delay_to_start_navigation">Salta la pianificazione del percorso</string>
|
||||
<string name="delay_to_start_navigation">Avvia la navigazione svolta per svolta dopo…</string>
|
||||
<string name="shared_string_go">Vai</string>
|
||||
<string name="shared_string_not_use">Non usare</string>
|
||||
<string name="confirmation_to_clear_history">Vuoi cancellare la cronologia?</string>
|
||||
|
@ -2162,7 +2162,9 @@ Si consiglia di aggiungere uno o più punti intermedi per migliorarne le prestaz
|
|||
<string name="welcome_header">Benvenuto</string>
|
||||
<string name="current_route">Percorso attuale</string>
|
||||
<string name="osm_changes_added_to_local_edits">Modifiche a OsmAnd aggiunte alle modifiche locali</string>
|
||||
<string name="mark_to_delete">Marca da eliminare</string>
|
||||
<string name="mark_to_delete">Contrassegna da eliminare</string>
|
||||
<string name="osmo_grop_name_length_alert">I nomi dei gruppi devono essere almeno di 3 caratteri!</string>
|
||||
<string name="shared_string_message">Messaggio</string>
|
||||
<string name="shared_string_do_not_use">Non usare</string>
|
||||
<string name="shared_string_address">Indirizzi</string>
|
||||
</resources>
|
||||
|
|
|
@ -2216,7 +2216,7 @@
|
|||
<string name="agps_data_last_downloaded">최근 다운로드한 A-GPS 데이터 : %1$ s</string>
|
||||
<string name="confirm_usage_speed_cameras">(독일, 프랑스, 이탈리아, 등) 많은 국가에서 속도 카메라 경고를 사용하는 것은 법률에 의해 허용 되지 않습니다. OsmAnd은 법률을 위반할 경우 어떤 책임도 지지 않습니다. 이 기능을 이해하는 경우에 [예] 를 클릭 하십시오.</string>
|
||||
<string name="welmode_download_maps">지도 다운로드</string>
|
||||
<string name="welcome_select_region">교통 표지판 및 규정을 제대로 반영 하기 위해 , 운전 지역을 선택 하십시오.</string>
|
||||
<string name="welcome_select_region">교통 표지판 및 규정을 제대로 반영 하기 위해 , 운전 지역을 선택 하십시오:</string>
|
||||
<string name="welcome_text">OsmAnd는 전세계 오프라인 지도 보기 및 전세계 오프라인 운행을 제공합니다!</string>
|
||||
<string name="welcome_header">환영 합니다</string>
|
||||
<string name="current_route">현재 루트</string>
|
||||
|
|
|
@ -1851,4 +1851,6 @@
|
|||
<string name="agps_info">A-GPS-info</string>
|
||||
<string name="shared_string_message">Meddelande</string>
|
||||
<string name="agps_data_last_downloaded">A-GPS-data senast nedladdat: %1$s</string>
|
||||
</resources>
|
||||
<string name="shared_string_do_not_use">Använd inte</string>
|
||||
<string name="shared_string_address">Adress</string>
|
||||
</resources>
|
||||
|
|