Merge branch 'master' of ssh://github.com/osmandapp/Osmand into fab_waypoints

# Conflicts:
#	OsmAnd/src/net/osmand/plus/views/MapControlsLayer.java
This commit is contained in:
PavelRatushny 2017-08-01 17:35:00 +03:00
commit a26a44c8ef
66 changed files with 1029 additions and 299 deletions

View file

@ -0,0 +1,138 @@
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/color_transparent"
android:clickable="true">
<LinearLayout
android:id="@+id/main_view"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:background="@drawable/bg_bottom_menu_dark"
android:clickable="true"
android:orientation="vertical">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingBottom="12dp"
android:paddingTop="12dp">
<ImageButton
android:id="@+id/ruler_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true"
android:layout_centerVertical="true"
android:layout_marginEnd="16dp"
android:layout_marginLeft="16dp"
android:layout_marginRight="16dp"
android:layout_marginStart="16dp"
android:background="@null"
tools:src="@drawable/ic_action_ruler"/>
<ImageButton
android:id="@+id/up_down_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
android:layout_marginEnd="16dp"
android:layout_marginLeft="16dp"
android:layout_marginRight="16dp"
android:layout_marginStart="16dp"
android:background="@null"
tools:src="@drawable/ic_action_arrow_down"/>
<TextView
android:id="@+id/measurement_distance_text_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginEnd="4dp"
android:layout_marginLeft="8dp"
android:layout_marginRight="4dp"
android:layout_marginStart="8dp"
android:layout_toEndOf="@id/ruler_icon"
android:layout_toRightOf="@id/ruler_icon"
android:textAppearance="@style/TextAppearance.ListItemTitle"
tools:text="724 m,"/>
<TextView
android:id="@+id/measurement_points_text_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_toEndOf="@id/measurement_distance_text_view"
android:layout_toLeftOf="@id/up_down_icon"
android:layout_toRightOf="@id/measurement_distance_text_view"
android:layout_toStartOf="@id/up_down_icon"
android:textColor="?android:textColorSecondary"
android:textSize="@dimen/default_list_text_size"
tools:text="points: 3"/>
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="?attr/dashboard_divider"/>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<ImageButton
android:id="@+id/previous_dot_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true"
android:layout_centerVertical="true"
android:layout_marginEnd="16dp"
android:layout_marginLeft="16dp"
android:layout_marginRight="16dp"
android:layout_marginStart="16dp"
android:background="@null"
tools:src="@drawable/ic_action_undo_dark"/>
<ImageButton
android:id="@+id/next_dot_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="8dp"
android:layout_marginStart="8dp"
android:layout_toEndOf="@id/previous_dot_icon"
android:layout_toRightOf="@id/previous_dot_icon"
android:background="@null"
tools:src="@drawable/ic_action_redo_dark"/>
<Button
android:id="@+id/add_point_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
android:layout_marginBottom="8dp"
android:layout_marginEnd="8dp"
android:layout_marginRight="8dp"
android:layout_marginTop="8dp"
android:background="@drawable/btn_round_blue"
android:drawableLeft="@drawable/ic_action_plus"
android:minHeight="36dp"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:text="@string/shared_string_add"
android:textColor="@color/color_white"/>
</RelativeLayout>
</LinearLayout>
</FrameLayout>

View file

@ -922,10 +922,10 @@
<string name="lang_en_gb">İngiliscə (Birləşmiş Krallıq)</string>
<string name="lang_af">Afrikanca</string>
<string name="lang_al">Albanca</string>
<string name="lang_eu">Bask dili</string>
<string name="lang_eu">Baskca</string>
<string name="lang_hu_formal">Macarca (rəsmi)</string>
<string name="lang_id">İndoneziya dili</string>
<string name="lang_ko">Koreya dili</string>
<string name="lang_id">İndonez</string>
<string name="lang_ko">Koreyaca</string>
<string name="route_descr_select_destination">Təyinat nöqtəsi seçin</string>
<string name="routing_attr_avoid_toll_description">Pullu yollardan yayın</string>
<string name="routing_attr_avoid_unpaved_name">Asfaltsız yollardan yayın</string>
@ -973,7 +973,7 @@
<string name="open_mapillary">Mapillary-ni aç</string>
<string name="no_photos_descr">Bu məkan üçün şəkillərimiz yoxdur</string>
<string name="subscribe_email_desc">Proqramın endirimləri haqqında e-poçt siyahımıza abunə olun və əlavə 3 xəritə endirməsi əldə edin!</string>
<string name="sea_depth_thanks">Dəniz dərinliyi konturlarını aldığınız üçün təşəkkürlər!</string>
<string name="sea_depth_thanks">Dəniz dərinliyi konturlarını aldığınız üçün təşəkkür edirik!</string>
<string name="index_item_depth_contours_osmand_ext">Dəniz dərinliyi konturları</string>
<string name="index_item_depth_points_southern_hemisphere">Dəniz dərinliyi cənub yarımkürəsində göstərilir</string>
<string name="download_depth_countours">Dəniz dərinliyi konturları</string>
@ -1050,7 +1050,7 @@
<string name="rendering_value_americanRoadAtlas_name">Amerika yol atlası</string>
<string name="impassable_road">Yollardan yayın…</string>
<string name="routing_attr_avoid_toll_name">Pullu yollardan yayın</string>
<string name="ending_point_too_far">Son nöqtə ən yaxın yoldan çox uzaqdadır.</string>
<string name="ending_point_too_far">Son nöqtə ən yaxın yoldan çox uzaqdır.</string>
<string name="snap_to_road_descr">Naviqasiya zamanı mövqeni yollara bərkit</string>
<string name="snap_to_road">Yola bərkit</string>
<string name="avoid_unpaved">Asfaltsız yollardan yayın</string>
@ -1658,4 +1658,40 @@
<string name="osm_edit_created_poi">Yaradılmış OSM POI</string>
<string name="rendering_value_translucent_pink_name">Şəffaf çəhrayı</string>
<string name="confirm_usage_speed_cameras">Bir çox ölkələrdə (Almaniya, Fransa, İtaliya və s.) sürət kamerası xəbərdarlıqlarının istifadə edilməsinə qanunla icazə verilmir. Qanunu pozarsanız, OsmAnd heç bir məsuliyyət daşımır. Yalnız bu xüsusiyyətdən istifadəyə icazə varsa, Bəli düyməsinə toxunun.</string>
<string name="lang_ml">Malayalamca</string>
<string name="lang_sw">Suahilicə</string>
<string name="lang_bs">Boşnakca</string>
<string name="lang_bg">Bolqarca</string>
<string name="lang_ca">Katalanca</string>
<string name="lang_hr">Xorvatca</string>
<string name="lang_da">Danimarkaca</string>
<string name="lang_kn">Kannadaca</string>
<string name="lang_lv">Latışca</string>
<string name="lang_lt">Litvaca</string>
<string name="lang_mr">Marathicə</string>
<string name="lang_no">Norveçcə</string>
<string name="lang_pl">Polyakca</string>
<string name="lang_sr">Serbcə</string>
<string name="lang_sr_latn">Serbcə (Latın)</string>
<string name="lang_sk">Slovakca</string>
<string name="lang_sl">Slovencə</string>
<string name="use_high_res_maps">Yüksək dəqiqlikli ekran</string>
<string name="transport_searching_transport">Nəqliyyat nəticələri (təyinat nöqtəsi yoxdur):</string>
<string name="transport_searching_route">Nəqliyyat nəticələri (təyinat nöqtəsinə {0}):</string>
<string name="transport_search_again">Nəqliyyat axtarışını sıfırla</string>
<string name="voice">Qeyd edilən səs</string>
<string name="no_vector_map_loaded">Vektor xəritələr yüklənməyib</string>
<string name="vector_data">Offlayn vektor xəritələr</string>
<string name="transport_context_menu">Dayanacaqda nəqliyyat axtar</string>
<string name="show_route">Marşrut detalları</string>
<string name="no_fav_to_save">Yadda saxlanacaq favorit nöqtələr yoxdur</string>
<string name="share_fav_subject">Favoritlər OsmAnd ilə paylaşılıb</string>
<string name="error_occurred_loading_gpx">GPX yüklənərkən səhv baş verdi</string>
<string name="thanks_yandex_traffic">Trafik məlumatları üçün Yandex-ə təşəkkürlər.</string>
<string name="layer_yandex_traffic">Yandex trafik</string>
<string name="layer_route">Marşrut</string>
<string name="layer_osm_bugs">OSM qeydlər (onlayn)</string>
<string name="search_near_map">Hazırki xəritə mərkəzinin yaxınında axtar</string>
<string name="transport_Routes">Marşrutlar</string>
<string name="transport_Stop">Dayanacaq</string>
</resources>

View file

@ -2554,7 +2554,7 @@ Pokud potřebujete pomoci s aplikací OsmAnd, prosím kontaktujte naši podporu
<string name="routing_attr_relief_smoothness_factor_hills_name">Kopcovitý</string>
<string name="routing_attr_relief_smoothness_factor_plains_name">Méně kopcovitý</string>
<string name="routing_attr_relief_smoothness_factor_more_plains_name">Rovinatý</string>
<string name="routing_attr_driving_style_speed_name">Preferovat hlavní silnice</string>
<string name="routing_attr_driving_style_speed_name">Kratší trasy</string>
<string name="routing_attr_driving_style_balance_name">Vyvážený</string>
<string name="routing_attr_driving_style_safety_name">Preferovat vedlejší silnice</string>
<string name="relief_smoothness_factor_descr">Priorita terénu: rovinatý nebo kopcovitý</string>
@ -2676,4 +2676,19 @@ Pokud potřebujete pomoci s aplikací OsmAnd, prosím kontaktujte naši podporu
<string name="max_min">Max/Min</string>
<string name="min_max">Min/Max</string>
<string name="quick_action_resume_pause_navigation">Pokračovat/Pozastavit navigaci</string>
<string name="quick_action_resume_pause_navigation_descr">Stiskněte toto tlačítko na pozastavení navigace, nebo pokračování pokud je pozastavená.</string>
<string name="quick_action_show_navigation_finish_dialog">Zobrazit zprávu o ukončení navigace</string>
<string name="quick_action_start_stop_navigation">Spustit/Ukončit navigaci</string>
<string name="quick_action_start_stop_navigation_descr">Stiskněte toto tlačítko pro spuštění navigace, nebo zastavení, pokud již byla spuštěna.</string>
<string name="release_2_7">"\\022 Modul Mapillary se snímky ulic
\n
\n • Pravítko pro měření vzdálenosti
\n
\n • Intervaly rozdělení GPX s detailními informacemi o trase
\n
\n • další vylepšení a opravy chyb
\n
\n"</string>
<string name="rendering_value_translucent_pink_name">Průhledná růžová</string>
</resources>

View file

@ -3497,7 +3497,7 @@
<string name="poi_animal_shelter_type">Dyr accepteres</string>
<string name="poi_animal_shelter_purpose">Formål</string>
<string name="poi_animal_shelter_wildlife">Vilde dyr og planter</string>
<string name="poi_animal_shelter_wildlife">Vilde dyr</string>
<string name="poi_animal_shelter_horse">Heste</string>
<string name="poi_animal_shelter_mammal">Pattedyr</string>
<string name="poi_animal_shelter_fish">Fisk</string>

View file

@ -705,7 +705,7 @@ OSM er et i fællesskab drevet, globalt offentligt domæne kortlægningsprojekt.
<string name="amenity_type_landuse">Arealanvendelse</string>
<string name="amenity_type_sustenance">Mad og drikke</string>
<string name="voice_is_not_available_msg">Talevejledning er ikke tilgængelig. Gå til \'Indstillinger\' → \'Generelt\' → \'Talevejledning\' og vælg eller hent en talevejledning.</string>
<string name="voice_is_not_available_msg">Talevejledning er ikke tilgængelig. Gå til \'Indstillinger\' → \'Navigation\' → \'Talevejledning\' og vælg eller hent en talevejledning.</string>
<string name="items_were_selected">{0} emner valgt</string>
<string name="filter_existing_indexes">Hentet</string>
<string name="fast_route_mode">Hurtigste rute</string>
@ -2449,7 +2449,7 @@ Hvis du ønsker at støtte OsmAnd og OSM, er dette en god måde at gøre det p
<string name="christmas_desc_q">Vis jule-interessepunkter (IP)?</string>
<string name="save_track_min_speed">Minimumshastighed for logning</string>
<string name="save_track_min_speed_descr">Filter: Angiv minimumshastighed før et punkt logges</string>
<string name="save_track_min_distance">Logning ved minimum bevægelse</string>
<string name="save_track_min_distance">Logning ved minimum forskydning</string>
<string name="save_track_min_distance_descr">Filter: Indstil minimumsafstand fra sidste position før et punkt logges</string>
<string name="save_track_precision">Mindste nøjagtighed for logning</string>
<string name="save_track_precision_descr">Filter: Indstil minimum nøjagtighed før et punkt logges</string>
@ -2723,7 +2723,7 @@ Tidligere destination bliver sidste mellemliggende punkt.</string>
<string name="shared_string_in_name">i %1$s</string>
<string name="shared_string_overview">Oversigt</string>
<string name="animate_my_location">Animér position</string>
<string name="animate_my_location_desc">Aktiver kort panorering animation af position under navigation</string>
<string name="animate_my_location_desc">Aktiver panorering af positionen under navigation</string>
<string name="favorite_group_name">Gruppenavn</string>
<string name="change_color">Skift farve</string>
<string name="edit_name">Rediger navn</string>
@ -2779,7 +2779,7 @@ Tidligere destination bliver sidste mellemliggende punkt.</string>
<string name="mapillary_menu_edit_text_hint">Indtast brugernavn</string>
<string name="mapillary_menu_descr_username">Se billeder tilføjet af en bestemt bruger.</string>
<string name="mapillary_menu_title_username">Brugernavn</string>
<string name="mapillary_menu_filter_description">Filtrer billeder efter indsender eller dato. Filter gælder kun for højere zoom.</string>
<string name="mapillary_menu_filter_description">Filtrer billeder efter indsender eller dato. Filter gælder kun for højere zoomniveauer.</string>
<string name="mapillary_menu_descr_dates">Se billeder tilføjet i en bestemt periode.</string>
<string name="shared_string_reload">Genindlæs</string>
<string name="mapillary_menu_descr_tile_cache">Genindlæs kortbrikker for at se opdaterede data.</string>
@ -2811,7 +2811,7 @@ Tidligere destination bliver sidste mellemliggende punkt.</string>
<string name="quick_action_start_stop_navigation">Start/stop navigation</string>
<string name="quick_action_start_stop_navigation_descr">Tryk på knappen for at starte navigation eller stoppe, hvis den allerede var begyndt.</string>
<string name="live_monitoring_max_interval_to_send">Tidsbuffer til online sporing</string>
<string name="live_monitoring_max_interval_to_send_desrc">Angiv en tidsbuffer til at opbevare steder, når der ingen forbindelse er</string>
<string name="live_monitoring_max_interval_to_send_desrc">Angiv en buffer for hvor lang tid positioner skal gemmes, når der ingen internetforbindelse er</string>
<string name="retry">Prøv igen</string>
<string name="mappilary_no_internet_desc">Internetforbindelse er nødvendig for at se fotos fra Mapillary</string>
</resources>

View file

@ -225,7 +225,7 @@ Lon %2$s</string>
<string name="enable_sleep_mode">Activar modo reposo del GPS</string>
<string name="save_current_track_descr">Guarda ahora la traza actual en la SD</string>
<string name="save_current_track">Guardar traza GPX actual</string>
<string name="save_track_interval_globally">Intervalo de guardado</string>
<string name="save_track_interval_globally">Intervalo de registro</string>
<string name="voice_provider">Indicaciones por voz</string>
<string name="enable_proxy_title">Activar Proxy HTTP</string>
<string name="proxy_port_title">Puerto Proxy</string>
@ -517,14 +517,14 @@ Se aprecia la participación activa, y las contribuciones pueden hacerse directa
<string name="background_service_is_enabled_question">El servicio de fondo, aún está funcionando. ¿Quieres pararlo también?</string>
<string name="sleep_mode_stop_dialog">¿Parar modo reposo del GPS?</string>
<string name="save_global_track_interval_descr">Elige el intervalo de registro para la grabación de trazas general (activar mediante el control de grabación GPX en el mapa)</string>
<string name="save_global_track_interval">Intervalo general de guardado</string>
<string name="save_global_track_interval">Intervalo de registro general</string>
<string name="background_service_int">Intervalo de activación del GPS</string>
<string name="save_track_to_gpx_globally">Guardar traza en archivo GPX</string>
<string name="save_track_to_gpx_globally_headline">Registro de trazas bajo demanda</string>
<string name="save_track_to_gpx_globally_descr">Registra la ubicación en un archivo GPX, pudiendo des/activarlo usando el control de grabación GPX en la pantalla del mapa</string>
<string name="save_track_to_gpx">Guardar la traza automáticamente durante la navegación</string>
<string name="save_track_to_gpx_descrp">Una traza GPX se guardará automáticamente en la carpeta de trazas durante la navegación</string>
<string name="save_track_interval">Intervalo de guardado durante navegación</string>
<string name="save_track_interval">Intervalo de registro durante navegación</string>
<string name="save_track_interval_descr">Elige el intervalo de registro de trazas durante la navegación</string>
<string name="voice_provider_descr">Elige las indicaciones por voz para la navegación</string>
<string name="enable_proxy_descr">Configura un Proxy HTTP para todas las peticiones de red</string>
@ -2063,7 +2063,7 @@ Se aprecia la participación activa, y las contribuciones pueden hacerse directa
<string name="select_map_marker">Elegir marcador del mapa</string>
<string name="map_markers_other">Otros marcadores</string>
<string name="upload_anonymously">Subir anónimamente</string>
<string name="show_transparency_seekbar">Mostrar transparencia en barra de búsqueda</string>
<string name="show_transparency_seekbar">Mostrar barra de transparencia en el mapa</string>
<string name="upload_osm_note_description">Puedes subir informes de problemas anónimos o usar tu perfil de OpenStreetMap.org.</string>
<string name="upload_osm_note">Subir problema(s) del mapa</string>
<string name="donations">Donaciones</string>
@ -2694,8 +2694,8 @@ Proporciona un código completo</string>
<string name="quick_action_show_navigation_finish_dialog">Mostrar diálogo de Finalizar navegación</string>
<string name="quick_action_start_stop_navigation">Iniciar/Parar navegación</string>
<string name="quick_action_start_stop_navigation_descr">Pulsa este botón para iniciar la navegación, o para finalizarla si ya se había iniciado.</string>
<string name="live_monitoring_max_interval_to_send">Tiempo del búfer para la seguimiento en línea</string>
<string name="live_monitoring_max_interval_to_send_desrc">Especifica el tiempo del búfer para mantener lugares para enviar sin conexión</string>
<string name="live_monitoring_max_interval_to_send">Tiempo del búfer para el seguimiento en línea</string>
<string name="live_monitoring_max_interval_to_send_desrc">Especifica el tiempo que el búfer mantendrá los lugares para enviar sin conexión</string>
<string name="mappilary_no_internet_desc">Debes tener conexión a Internet para ver fotos de Mapillary</string>
<string name="retry">Reintentar</string>
</resources>

View file

@ -225,7 +225,7 @@ Lon %2$s</string>
<string name="enable_sleep_mode">Activar modo reposo del GPS</string>
<string name="save_current_track_descr">Guarda ahora la traza actual en la SD</string>
<string name="save_current_track">Guardar traza GPX actual</string>
<string name="save_track_interval_globally">Intervalo de guardado</string>
<string name="save_track_interval_globally">Intervalo de registro</string>
<string name="voice_provider">Indicaciones por voz</string>
<string name="enable_proxy_title">Activar Proxy HTTP</string>
<string name="proxy_port_title">Puerto Proxy</string>
@ -517,14 +517,14 @@ Se aprecia la participación activa, y las contribuciones pueden hacerse directa
<string name="background_service_is_enabled_question">El servicio de fondo, aún está funcionando. ¿Quieres pararlo también?</string>
<string name="sleep_mode_stop_dialog">¿Parar modo reposo del GPS?</string>
<string name="save_global_track_interval_descr">Elige el intervalo de registro para la grabación de trazas general (activar mediante el control de grabación GPX en el mapa)</string>
<string name="save_global_track_interval">Intervalo general de guardado</string>
<string name="save_global_track_interval">Intervalo de registro general</string>
<string name="background_service_int">Intervalo de activación del GPS</string>
<string name="save_track_to_gpx_globally">Guardar traza en archivo GPX</string>
<string name="save_track_to_gpx_globally_headline">Registro de trazas bajo demanda</string>
<string name="save_track_to_gpx_globally_descr">Registra la ubicación en un archivo GPX, pudiendo des/activarlo usando el control de grabación GPX en la pantalla del mapa</string>
<string name="save_track_to_gpx">Guardar la traza automáticamente durante la navegación</string>
<string name="save_track_to_gpx_descrp">Una traza GPX se guardará automáticamente en la carpeta de trazas durante la navegación</string>
<string name="save_track_interval">Intervalo de guardado durante navegación</string>
<string name="save_track_interval">Intervalo de registro durante navegación</string>
<string name="save_track_interval_descr">Elige el intervalo de registro de trazas durante la navegación</string>
<string name="voice_provider_descr">Elige las indicaciones por voz para la navegación</string>
<string name="enable_proxy_descr">Configura un Proxy HTTP para todas las peticiones de red</string>
@ -2088,7 +2088,7 @@ Si amas a OsmAnd, OSM y quieres apoyarlos, esta es una perfecta manera de hacerl
<string name="select_map_marker">Elegir marcador del mapa</string>
<string name="map_markers_other">Otros marcadores</string>
<string name="upload_anonymously">Subir anónimamente</string>
<string name="show_transparency_seekbar">Mostrar transparencia en barra de búsqueda</string>
<string name="show_transparency_seekbar">Mostrar barra de transparencia en el mapa</string>
<string name="upload_osm_note_description">Puedes subir informes de problemas anónimos o usar tu perfil de OpenStreetMap.org.</string>
<string name="upload_osm_note">Subir problema(s) del mapa</string>
<string name="recalculate_route">Recalcular ruta</string>
@ -2696,7 +2696,7 @@ Proporciona un código completo</string>
<string name="quick_action_start_stop_navigation">Iniciar/Parar navegación</string>
<string name="quick_action_start_stop_navigation_descr">Pulsa este botón para iniciar la navegación, o para finalizarla si ya se había iniciado.</string>
<string name="live_monitoring_max_interval_to_send">Tiempo del búfer para el seguimiento en línea</string>
<string name="live_monitoring_max_interval_to_send_desrc">Especifica el tiempo del búfer para mantener lugares para enviar sin conexión</string>
<string name="live_monitoring_max_interval_to_send_desrc">Especifica el tiempo que el búfer mantendrá los lugares para enviar sin conexión</string>
<string name="mappilary_no_internet_desc">Debes tener conexión a Internet para ver fotos de Mapillary</string>
<string name="retry">Reintentar</string>
</resources>

View file

@ -2198,4 +2198,7 @@
<string name="poi_lock_basin">Esklusako atea</string>
<string name="poi_notice">Itsas oharra</string>
<string name="poi_pile">Pilote</string>
<string name="poi_wiki_lang_bs">Wikia bosnieraz</string>
<string name="poi_bicycle_parking_wall_loops">Hormako begiztak</string>
<string name="poi_capacity">Ahalmena</string>
</resources>

View file

@ -2746,4 +2746,6 @@ Area honi dagokio: %1$s x %2$s</string>
<string name="quick_action_start_stop_navigation_descr">Sakatu boti hau nabigazioa hasteko, edo gelditzeko hasita bazegoen.</string>
<string name="live_monitoring_max_interval_to_send">Lineako jarraipenaren denbora-bufferra</string>
<string name="live_monitoring_max_interval_to_send_desrc">Zehaztu bidaltzeke dauden kokalekuak gordetzeko denbora-buffer bat</string>
</resources>
<string name="mappilary_no_internet_desc">Internet behar duzu Mapillary-ko argazkiak ikusteko</string>
<string name="retry">Saiatu berriro</string>
</resources>

View file

@ -1428,4 +1428,6 @@
<string name="poi_payment_sms_yes">Pagamentos por SMS</string>
<string name="poi_payment_sms_no">Non acepta pagamentos por SMS</string>
<string name="poi_payment_ov_chipkaart_yes">OV-Chipkaart</string>
<string name="poi_cafeteria">Cafetaría</string>
<string name="poi_zoo_type">Tipo</string>
</resources>

View file

@ -1,4 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><resources><string name="fav_point_dublicate_message">O nome do punto favorito xa está usado; foi cambiado a %1$s para evitar os duplicados.</string>
<?xml version='1.0' encoding='UTF-8'?>
<resources><string name="fav_point_dublicate_message">O nome do punto favorito xa está usado; foi cambiado a %1$s para evitar os duplicados.</string>
<string name="text_size_descr">Configurar o tamaño da letra no mapa.</string>
<string name="text_size">Tamaño da letra</string>
<string name="traffic_warning_speed_limit">Límite de velocidade</string>
@ -2494,7 +2495,7 @@ Pódese pechar esta vista desactivándoa aquí ou cambiando o «Estilo de mapa»
<string name="total_distance">Distancia total</string>
<string name="routing_attr_height_obstacles_name">Empregar datos de elevación</string>
<string name="shared_string_plugin">Engadido</string>
<string name="srtm_purchase_header">Para ver as liñas de nivel no mapa hai que comprar e instalar un engadido</string>
<string name="srtm_purchase_header">Para ver as liñas de nivel no mapa hai que comprar e instalar o engadido Liñas de Nivel</string>
<string name="srtm_color_scheme">Esquema de cores</string>
<string name="routing_attr_allow_private_name">Permitir acceso privado</string>
<string name="routing_attr_allow_private_description">Permitir acceso a zonas privadas</string>
@ -2505,10 +2506,45 @@ Pódese pechar esta vista desactivándoa aquí ou cambiando o «Estilo de mapa»
<string name="lang_ber">Bérber</string>
<string name="lang_kn">Kannada</string>
<string name="shared_string_install">Instalar</string>
<string name="improve_coverage_mapillary">Mellorar a cobertura con Mapillary</string>
<string name="improve_coverage_mapillary">Mellorar a cobertura de fotos con Mapillary</string>
<string name="open_mapillary">Abrir Mapillary</string>
<string name="improve_coverage_install_mapillary_desc">Podes facer as túas propias fotos ou serie de fotos e engadilas a esta localización do mapa.
<string name="improve_coverage_install_mapillary_desc">Podes facer as túas propias fotos ou serie de fotos e engadilas a este lugar do mapa.
\n
\nPara facer isto, tes que instalar a aplicación Mapillary dende Google Play.</string>
<string name="online_photos">Fotos en liña</string>
\nPara facer isto, hai que instalar a aplicación Mapillary dende Google Play.</string>
<string name="online_photos">Fotos da rede</string>
<string name="quick_action_resume_pause_navigation">Retomar/Deter a navegación</string>
<string name="quick_action_resume_pause_navigation_descr">Prema neste botón para deter a navegación, ou para retomala se xa estaba detida.</string>
<string name="quick_action_start_stop_navigation">Iniciar/Rematar a navegación</string>
<string name="quick_action_start_stop_navigation_descr">Prema neste botón para iniciar a navegación, ou para detela se xa estaba iniciada.</string>
<string name="store_tracks_in_monthly_directories">Almacenar as pistas gravadas en cartafoles mensuais</string>
<string name="store_tracks_in_monthly_directories_descrp">Almacenar as pistas gravadas en sub-cartafoles segundo o mes de gravación (como 2017-01).</string>
<string name="shared_string_reset">Restaurar</string>
<string name="shared_string_reload">Recargar</string>
<string name="mapillary_menu_descr_tile_cache">Recargar as teselas para ver datos actualizados.</string>
<string name="mapillary_menu_title_tile_cache">Caché de teselas</string>
<string name="wrong_user_name">O nome de usuario é incorrecto!</string>
<string name="shared_string_to">A</string>
<string name="mapillary_menu_date_from">Desde</string>
<string name="mapillary_menu_descr_dates">Ver as imaxes engadidas nun período determinado.</string>
<string name="mapillary_menu_title_dates">Datas</string>
<string name="mapillary_menu_edit_text_hint">Escriba o nome de usuario</string>
<string name="mapillary_menu_descr_username">Ver as imaxes engadidas por un usuario determinado.</string>
<string name="mapillary_menu_title_username">Nome de usuario</string>
<string name="mapillary_menu_filter_description">Pode filtrar as imaxes por quen as enviou ou pola data. Os filtros só se aplican na ampliación próxima.</string>
<string name="shared_string_permissions">Permisos</string>
<string name="import_gpx_failed_descr">O OsmAnd non pode importar o ficheiro. Comprobe se o OsmAnd ten permiso para ler o ficheiro neste sitio.</string>
<string name="distance_moving">Distancia corrixida</string>
<string name="mapillary_image">Imaxe de Mapillary</string>
<string name="shared_string_add_photos">Engadir fotos</string>
<string name="no_photos_descr">Non dispomos de fotos deste lugar</string>
<string name="mapillary_widget">Trebello de Mapillary</string>
<string name="mapillary">Mapillary</string>
<string name="restart_search">Reiniciar a busca</string>
<string name="increase_search_radius">Aumentar o radio de busca</string>
<string name="nothing_found">Non se atopou nada :(</string>
<string name="quick_action_showhide_osmbugs_title">Mostrar/Agochar as notas de OSM</string>
<string name="quick_action_osmbugs_show">Mostrar as notas de OSM</string>
<string name="quick_action_osmbugs_hide">Agochar as notas de OSM</string>
<string name="sorted_by_distance">Ordenado por distancia</string>
<string name="search_favorites">Buscar nos favoritos</string>
</resources>

View file

@ -39,7 +39,7 @@
<dimen name="map_button_inset_shadow">3dp</dimen>
<dimen name="map_button_inset">3dp</dimen>
<dimen name="map_button_rect_rad">4dp</dimen>
<dimen name="map_button_rect_rad">3dp</dimen>
<dimen name="map_widget_icon_margin">3dp</dimen>

View file

@ -1,4 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><resources><string name="plugins_screen">Spraudņu pārvaldnieks</string>
<?xml version='1.0' encoding='UTF-8'?>
<resources><string name="plugins_screen">Spraudņu pārvaldnieks</string>
<string name="prefs_plugins_descr">Spraudņi papildina aplikācijas iespējas un piešķir tai papildus funkcionalitāti</string>
<string name="prefs_plugins">Spraudņi</string>
@ -2399,13 +2400,13 @@ failu(s)?
<string name="skip_map_downloading_desc">Jums nav instalētas nevienas bezsaistes kartes. Izvēlieties kartes no saraksta vai lejuielādējiet tās caur izvēlni - %1$s.</string>
<string name="search_another_country">Izvēlieties citu reģionu</string>
<string name="search_map">Meklē karti…</string>
<string name="first_usage_wizard_desc">Nosakot jūsu atrašanās vietu, OsmAnd piedāvā sekojošas kartes lejupielādei.</string>
<string name="first_usage_wizard_desc">OsmAnd noteiks jūsu atrašanos un piedāvās lejupielādēt šī reģiona karti.</string>
<string name="location_not_found">Atrašanās vieta nav zināma</string>
<string name="no_inet_connection">Nav interneta savienojuma</string>
<string name="no_inet_connection_desc_map">Nepieciešams lejupielādēt kartes.</string>
<string name="search_location">Meklē atrašanās vietu…</string>
<string name="storage_free_space">Brīvā vieta</string>
<string name="storage_place_description">OsmAnd datu glabātuve (kartēm, trekiem, u.t.t.): %1$s.</string>
<string name="storage_place_description">OsmAnd datu uzglabāšanas vieta (kartēm, maršrutiem u.c.): %1$s.</string>
<string name="give_permission">Dot atļauju</string>
<string name="allow_access_location">Atļaut noteikt vietu</string>
<string name="first_usage_greeting">Veidojiet maršrutus un atklājiet jaunas vietas bez interneta savienojuma</string>

View file

@ -2234,7 +2234,7 @@ Lengtegraad:\t\t%2$s</string>
<string name="clear_updates_proposition_message">Je kan gedownloade updates verwijderen en terugkeren naar de originele kaart</string>
<string name="add_time_span">Periode toevoegen</string>
<string name="road_blocked">Weg geblokkeerd</string>
<string name="shared_string_select">Selekteer</string>
<string name="shared_string_select">Selecteer</string>
<string name="reports_for">Verslag voor:</string>
<string name="data_is_not_available">Gegevens niet beschikbaar</string>
<string name="rendering_attr_hideUnderground_name">Ondergrondse objecten</string>

View file

@ -2815,4 +2815,6 @@ Zodpovedá oblasti: %1$s x %2$s</string>
<string name="min_max">Min/Max</string>
<string name="live_monitoring_max_interval_to_send">Časový zásobník pre online sledovanie</string>
<string name="live_monitoring_max_interval_to_send_desrc">Zadajte čas pokiaľ budú udržované pozície na odoslanie kým nie je pripojenie</string>
</resources>
<string name="mappilary_no_internet_desc">Na zobrazovanie fotografií z Mapillary potrebujete pripojenie na Internet</string>
<string name="retry">Skúsiť znova</string>
</resources>

View file

@ -2654,9 +2654,9 @@ Koda predstavlja območje: %1$s x %2$s</string>
<string name="routing_attr_relief_smoothness_factor_hills_name">Gričevnato</string>
<string name="routing_attr_relief_smoothness_factor_plains_name">Manj gričevnato</string>
<string name="routing_attr_relief_smoothness_factor_more_plains_name">Ravninsko</string>
<string name="routing_attr_driving_style_speed_name">Hitro</string>
<string name="routing_attr_driving_style_speed_name">Krajše poti</string>
<string name="routing_attr_driving_style_balance_name">Pretehtano</string>
<string name="routing_attr_driving_style_safety_name">Varno</string>
<string name="routing_attr_driving_style_safety_name">Vodi po stranpoteh</string>
<string name="relief_smoothness_factor_descr">Prednostna izbira terena: ravninsko ali gričevnato</string>
<string name="routing_attr_relief_smoothness_factor_name">Izbor razgibanosti terena</string>
<string name="do_not_send_anonymous_app_usage">Ne pošiljaj statističnih podatkov uporabe programa</string>
@ -2798,4 +2798,11 @@ Koda predstavlja območje: %1$s x %2$s</string>
\n
\n</string>
<string name="rendering_value_translucent_pink_name">Prosojna rožnata</string>
</resources>
<string name="quick_action_resume_pause_navigation_descr">Pritisnite gumb, če želite začasno zaustaviti navigacijo ali pa jo nadaljevati, če je gumb že pritisnjen.</string>
<string name="quick_action_show_navigation_finish_dialog">Pokaži pogovorno okno končanja navigacije</string>
<string name="quick_action_start_stop_navigation_descr">"Pritisnite gumb, če želite začeti navigacijo ali pa jo zaustaviti, če je že začeta."</string>
<string name="live_monitoring_max_interval_to_send">Časovni medpomnilnik za spletno sledenje</string>
<string name="live_monitoring_max_interval_to_send_desrc">Določitev časovnega medpomnilnika za ohranjanje trenutnega mesta pri pošiljanju brez povezave</string>
<string name="mappilary_no_internet_desc">Za ogled slik prek Mapillary je zahtevana omrežna povezava</string>
<string name="retry">Poskusi znova</string>
</resources>

View file

@ -45,7 +45,7 @@
<string name="osmand_rastermaps_plugin_description">"Цей втулок надає можливість отримати доступ до багатьох типів онлайн (так званих растрових) мап, від попередньо створених квадратів OpenStreetMap (на кшталт стилю Mapnik) до супутникових знімків та спеціальних шарів, таких як погодні, кліматичні та геологічні мапи, шари рельєфу й т.і.
\n
\nБудь яка з цих мап може використовуватись як основна мапа в OsmAnd, або як покриття чи підкладка до іншої основної мапи (наприклад стандартна оффлайнова мапа OsmAnd). Для того, щоб зробити більш помітною будь-яку мапу-підкладку, певні елементи векторної мапи OsmAnd можна легко сховати через меню \'Налаштування Мапи\'.
\nБудь яка з цих мап може використовуватись як основна мапа в OsmAnd, або як покриття чи підкладка до іншої основної мапи (наприклад стандартна оффлайнова мапа OsmAnd). Для того, щоб зробити більш помітною будь-яку мапу-підкладку, певні елементи векторної мапи OsmAnd можна легко сховати через меню „Налаштування Мапи“.
\n
\nКвадрати мап можна отримувати безпосередньо з онлайн-джерел або підготувати їх для оффлайнового використання (та вручну скопіювати в теку даних OsmAnd) у вигляді бази даних SQLite, яку можна створити за допомогою різноманітних сторонніх інструментів підготовки мап."</string>
<string name="osmand_background_plugin_description">Показує налаштування для активації навігації та запису маршрутів в фоновому режимі (екран вимкнено), періодично активуючи GPS.</string>
@ -665,7 +665,7 @@
<string name="shared_string_close">Закрити</string>
<string name="loading_data">Дані завантажуються…</string>
<string name="reading_indexes">Зчитування даних…</string>
<string name="previous_run_crashed">Помилка у роботі програми. Лог-файл знаходиться тут {0}. Будь ласка, напишіть розробнику про помилку (з вкладеним лог-файлом).</string>
<string name="previous_run_crashed">Помилка у роботі програми. Файл журналу знаходиться тут {0}. Будь ласка, напишіть розробнику про помилку (з вкладеним журнальним файлом).</string>
<string name="saving_gpx_tracks">Збереження GPX треків на SD…</string>
<string name="finished_task">Закінчено</string>
@ -2934,7 +2934,7 @@
<string name="max_min">Макс./мін.</string>
<string name="min_max">Мін/макс</string>
<string name="release_2_7">\\022 Втулок Mapillary з вуличними зображеннями
<string name="release_2_7"> Втулок Mapillary з вуличними зображеннями
\n
\n • Віджет-лінійка для вимірювання дистанцій
\n
@ -2951,4 +2951,6 @@
<string name="quick_action_start_stop_navigation_descr">Натисніть цю кнопку, щоб запустити навігацію або зупинити її, якщо вона вже була запущена.</string>
<string name="live_monitoring_max_interval_to_send">Час буферизації для онлайн-стеження</string>
<string name="live_monitoring_max_interval_to_send_desrc">Задає час буферизації для збереження місць для відправки в автономному режимі</string>
</resources>
<string name="mappilary_no_internet_desc">Вам потрібен Інтернет для перегляду фотографій від Mapillary</string>
<string name="retry">Повторити</string>
</resources>

View file

@ -1099,7 +1099,7 @@
<string name="gps_wake_up_timer">GPS 唤醒间隔</string>
<string name="favourites_edit_dialog_title">我的最爱信息</string>
<string name="simulate_your_location_stop_descr">停止模拟您的位置</string>
<string name="simulate_your_location_descr">使用模拟计算一个路线或记录为 GPX</string>
<string name="simulate_your_location_descr">使用计算得到的路线或者一条 GPX 记录模拟您的位置</string>
<string name="looking_up_address">查询地址</string>
<string name="av_locations_descr">GPS 文件附位置注解</string>
<string name="av_locations">位置</string>
@ -1540,9 +1540,9 @@
<string name="routing_attr_relief_smoothness_factor_hills_name">丘陵</string>
<string name="routing_attr_relief_smoothness_factor_plains_name">低丘陵</string>
<string name="routing_attr_relief_smoothness_factor_more_plains_name">平地</string>
<string name="routing_attr_driving_style_speed_name">速度</string>
<string name="routing_attr_driving_style_speed_name">更短的路径</string>
<string name="routing_attr_driving_style_balance_name">平衡</string>
<string name="routing_attr_driving_style_safety_name">安全</string>
<string name="routing_attr_driving_style_safety_name">偏好背街小路</string>
<string name="relief_smoothness_factor_descr">首选的地形︰ 平坦或丘陵</string>
<string name="shared_string_slope">坡度</string>
<string name="add_new_folder">添加新文件夹</string>
@ -1587,7 +1587,7 @@
<string name="shared_string_recorded">已录制</string>
<string name="shared_string_record">记录</string>
<string name="rendering_attr_contourColorScheme_description">等高线的色彩调配</string>
<string name="save_track_min_distance">记录运动检测</string>
<string name="save_track_min_distance">最低位移记录阈值</string>
<string name="save_track_min_distance_descr">过滤器:从最后位置的一个点设置最短距离用以记录</string>
<string name="save_track_precision">记录最小的精确度</string>
<string name="save_track_precision_descr">过滤器:设置记录一个点的最小精度</string>
@ -1671,9 +1671,9 @@
<string name="map_widget_magnetic_bearing">磁方位</string>
<string name="map_widget_bearing">相对方位</string>
<string name="access_disable_offroute_recalc">当您离开道路时不重新计算路线</string>
<string name="access_disable_offroute_recalc_descr">当您离正确的道路很远,阻止自动路线重新估算</string>
<string name="access_disable_wrong_direction_recalc">不要改变错误方向的路线</string>
<string name="access_disable_wrong_direction_recalc_descr">当你正朝着错误的方向行进,防止自动路线重新计算</string>
<string name="access_disable_offroute_recalc_descr">当您偏离预设路线时,阻止自动路线重新估算</string>
<string name="access_disable_wrong_direction_recalc">向反方向行驶时不要重新计算路线</string>
<string name="access_disable_wrong_direction_recalc_descr">当你朝着反方向行驶时,防止自动路线重新计算</string>
<string name="access_smart_autoannounce">智能自动播报</string>
<string name="access_smart_autoannounce_descr">只在指引到目标点已被改变了才通知</string>
<string name="access_autoannounce_period">自动播报周期</string>
@ -1888,7 +1888,7 @@
<string name="watch">观看</string>
<string name="notes">注解</string>
<string name="rendering_attr_pisteRoutes_name">滑雪场</string>
<string name="free">"%1$s 可用 "</string>
<string name="free">%1$s 可用</string>
<string name="rendering_attr_pisteGrooming_name">滑雪道修整</string>
<string name="world_ski_missing">为了显示滑雪地图,需要下载特别的离线地图</string>
<string name="nautical_maps_missing">为了显示航海地图,需要下载特别的离线地图</string>
@ -2036,20 +2036,20 @@
\n
\n长按在地图上查看"</string>
<string name="delay_navigation_start">自动启动转弯指引</string>
<string name="gpx_info_subtracks">"子轨迹:%1$s "</string>
<string name="gpx_info_waypoints">"路标:%1$s "</string>
<string name="gpx_info_distance">"距离:%1$s%2$s 个点) "</string>
<string name="gpx_info_start_time">"开始时间:%1$tF%1$tT "</string>
<string name="gpx_info_end_time">"结束时间:%1$tF%1$tT "</string>
<string name="gpx_info_average_speed">"平均速度:%1$s "</string>
<string name="gpx_info_maximum_speed">"最大速度:%1$s "</string>
<string name="gpx_info_subtracks">子轨迹:%1$s</string>
<string name="gpx_info_waypoints">航点:%1$s</string>
<string name="gpx_info_distance">距离:%1$s%2$s 个点)</string>
<string name="gpx_info_start_time">开始时间:%1$tF%1$tT</string>
<string name="gpx_info_end_time">结束时间:%1$tF%1$tT</string>
<string name="gpx_info_average_speed">平均速度:%1$s</string>
<string name="gpx_info_maximum_speed">最大速度:%1$s</string>
<string name="gpx_info_avg_altitude">平均海拔高度:%1$s</string>
<string name="gpx_info_diff_altitude">高度范围:%1$s</string>
<string name="gpx_info_asc_altitude">下坡/上坡:%1$s</string>
<string name="gpx_timespan">时间跨度:%1$s</string>
<string name="gpx_timemoving">时间移动:%1$s</string>
<string name="gpx_selection_segment_title">区段</string>
<string name="gpx_selection_number_of_points">" %1$s 的标点"</string>
<string name="gpx_selection_number_of_points">%1$s 的标点</string>
<string name="gpx_selection_point">标点 %1$s</string>
<string name="gpx_selection_route_points">%1$s
\n路线标点 %2$s</string>
@ -2105,9 +2105,9 @@
<string name="osmo_connected_devices">已连接的设备</string>
<string name="osmo_session_token">会话令牌: %1$s</string>
<string name="osmo_auth_pending">正在等待授权…</string>
<string name="osmo_locations_sent">"位置已发送 %1$d缓冲区 %2$d "</string>
<string name="osmo_conn_successfull">"建立的连接: %1$s "</string>
<string name="osmo_io_error">"OsMo 连接问题: "</string>
<string name="osmo_locations_sent">位置已发送 %1$d缓冲区 %2$d</string>
<string name="osmo_conn_successfull">连接已建立: %1$s</string>
<string name="osmo_io_error">OsMo 连接问题:</string>
<string name="osmo_settings_uuid">独特的设备 id</string>
<string name="use_points_as_intermediates">计算两点之间的路线</string>
<string name="osmo_mode_restart">重新启动 OsMo 会话</string>
@ -2212,7 +2212,7 @@
<string name="app_mode_aircraft">航空器</string>
<string name="local_osm_changes_delete_all_confirm">要删除 %1$d 个 OSM 更新。是否确定?</string>
<string name="animate_routing_route_not_calculated">请先计算路线</string>
<string name="animate_routing_route">"模拟使用计算的路线 "</string>
<string name="animate_routing_route">使用计算的路线进行模拟</string>
<string name="animate_routing_gpx">模拟使用 GPX 轨迹</string>
<string name="route_is_too_long_v2">这条路线可能太长无法推算。如果在10分钟内没有结果请添加中继节点。</string>
<string name="auto_zoom_none">不自动缩放</string>
@ -2620,7 +2620,7 @@
<string name="mapillary_menu_title_dates">日期</string>
<string name="mapillary_menu_descr_username">查看特定用户添加的图像。</string>
<string name="mapillary_menu_descr_dates">查看特定时期内添加的图像。</string>
<string name="mapillary_menu_filter_description">您可以根据用户名或日期过滤图像</string>
<string name="mapillary_menu_filter_description">您可以根据提交者或日期过滤图像。过滤器仅在高比例尺放大时产生作用</string>
<string name="shared_string_reload">重新载入</string>
<string name="shared_string_reset">重置</string>
<string name="store_tracks_in_monthly_directories">按月将记录的轨迹存放在文件夹中</string>
@ -2633,4 +2633,19 @@
<string name="of">%2$d 中的 %1$d</string>
<string name="moving_time">移动时间</string>
<string name="min_max">最小/最大</string>
<string name="quick_action_resume_pause_navigation">继续/暂停导航</string>
<string name="quick_action_resume_pause_navigation_descr">点击该按钮以暂停导航,或者在已暂停时恢复导航。</string>
<string name="quick_action_show_navigation_finish_dialog">显示导航完成对话框</string>
<string name="quick_action_start_stop_navigation">开始/结束导航</string>
<string name="quick_action_start_stop_navigation_descr">点击该按钮以开始导航,或者在导航已经开始的情况下结束导航。</string>
<string name="release_2_7">\\022 带有街道等级图像的 Mapillary 插件
\n
\n• 用于距离测量的量尺小部件
\n
\n • GPX 切分间隔,带有您的路径的详细信息
\n
\n • 其它改进和问题修复
\n
\n</string>
<string name="rendering_value_translucent_pink_name">半透明粉红色</string>
</resources>

View file

@ -1494,7 +1494,7 @@ OsmAnd (Automated Navigation Directions) 是一個地圖和導航的應用程式
<string name="rendering_attr_showCycleRoutes_name">顯示自行車路線</string>
<string name="map_preferred_locale">地圖上優先的語言</string>
<string name="local_map_names">本地名稱</string>
<string name="local_map_names">當地的名稱</string>
<string name="lang_sw">斯瓦希里</string>
<string name="lang_he">希伯來</string>
<string name="forward">往前</string>
@ -1506,7 +1506,7 @@ OsmAnd (Automated Navigation Directions) 是一個地圖和導航的應用程式
<string name="gpx_monitoring_stop">停止 GPX 記錄</string>
<string name="gpx_start_new_segment">開始新區段</string>
<string name="lang_fa">波斯</string>
<string name="map_preferred_locale_descr">在地圖標簽上優先的語言(如果優先的語言無法使用,將會切換成英文或地名稱)</string>
<string name="map_preferred_locale_descr">在地圖標簽上優先的語言(如果優先的語言無法使用,將會切換成英文或地名稱)</string>
<string name="live_monitoring_m_descr">如果已啟用了 GPX 記錄,傳送軌跡資料到指定的 web 服務。</string>
<string name="keep_navigation_service">保持</string>
<string name="stop_navigation_service">中止</string>
@ -2804,4 +2804,6 @@ OsmAnd (Automated Navigation Directions) 是一個地圖和導航的應用程式
<string name="quick_action_start_stop_navigation_descr">按此按鈕開始導航如果已經開始,則停止導航。</string>
<string name="live_monitoring_max_interval_to_send">用於線上追蹤的緩衝時間</string>
<string name="live_monitoring_max_interval_to_send_desrc">指定一段緩衝時間以保持位置,而無需連接發送</string>
</resources>
<string name="mappilary_no_internet_desc">您需要網際網路才能從 Mapillary 檢視照片</string>
<string name="retry">重試</string>
</resources>

View file

@ -89,7 +89,7 @@
<dimen name="map_button_inset_shadow">2dp</dimen>
<dimen name="map_button_inset">2dp</dimen>
<dimen name="map_button_rect_rad">3dp</dimen>
<dimen name="map_button_rect_rad">2dp</dimen>
<dimen name="map_button_stroke">1dp</dimen>
<dimen name="map_button_stroke_dark">1dp</dimen>
<dimen name="map_route_planning_land_width">320dp</dimen>

View file

@ -9,6 +9,7 @@
3. All your modified/created strings are in the top of the file (to make easier find what\'s translated).
PLEASE: Have a look at http://code.google.com/p/osmand/wiki/UIConsistency, it may really improve your and our work :-) Thx - Hardy
-->
<string name="measurement_tool">Measurement tool</string>
<string name="quick_action_resume_pause_navigation">Resume/Pause Navigation</string>
<string name="quick_action_resume_pause_navigation_descr">Press this button to pause the navigation, or to resume it if it was already paused.</string>
<string name="quick_action_show_navigation_finish_dialog">Show Finish navigation dialog</string>

View file

@ -436,6 +436,12 @@ public class OsmandApplication extends MultiDexApplication {
}
}
});
builder.setNeutralButton(R.string.shared_string_do_not_use, new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
osmandSettings.VOICE_PROVIDER.set(OsmandSettings.VOICE_PROVIDER_NOT_USE);
}
});
builder.setView(view);
builder.show();

View file

@ -178,7 +178,7 @@ public abstract class OsmandPlugin {
allPlugins.add(srtm);
} else {
if (marketEnabled) {
srtm.setInstallURL(Version.marketPrefix(app) + id);
srtm.setInstallURL(Version.getUrlWithUtmRef(app, id));
allPlugins.add(srtm);
}
}

View file

@ -13,7 +13,7 @@ public class Version {
private final static String FREE_VERSION_NAME = "net.osmand";
private final static String FREE_DEV_VERSION_NAME = "net.osmand.dev";
private final static String SHERPAFY_VERSION_NAME = "net.osmand.sherpafy";
private final static String UTM_REF = "&referrer=utm_source%3Dosmand";
public static boolean isGpsStatusEnabled(OsmandApplication ctx) {
return isGooglePlayEnabled(ctx) && !isBlackberry(ctx);
@ -31,11 +31,15 @@ public class Version {
if (isAmazonEnabled(ctx)) {
return "amzn://apps/android?p=";
} else if (isGooglePlayEnabled(ctx)) {
return "market://search?q=pname:";
return "market://details?id=";
}
return "https://osmand.net/apps?id=";
}
public static String getUrlWithUtmRef(OsmandApplication ctx, String appName) {
return marketPrefix(ctx) + appName + UTM_REF;
}
private static boolean isAmazonEnabled(OsmandApplication ctx) {
return ctx.getString(R.string.versionFeatures).contains("+amazon");
}

View file

@ -754,7 +754,11 @@ public class MapActivity extends OsmandActionBarActivity implements DownloadEven
}
public void dismissCardDialog() {
getSupportFragmentManager().popBackStack(ContextMenuCardDialogFragment.TAG, FragmentManager.POP_BACK_STACK_INCLUSIVE);
try {
getSupportFragmentManager().popBackStack(ContextMenuCardDialogFragment.TAG, FragmentManager.POP_BACK_STACK_INCLUSIVE);
} catch (Exception e) {
e.printStackTrace();
}
}
@Override

View file

@ -48,6 +48,7 @@ import net.osmand.plus.dashboard.DashboardOnMap.DashboardType;
import net.osmand.plus.dialogs.FavoriteDialogs;
import net.osmand.plus.download.IndexItem;
import net.osmand.plus.liveupdates.OsmLiveActivity;
import net.osmand.plus.measurementtool.MeasurementToolFragment;
import net.osmand.plus.monitoring.OsmandMonitoringPlugin;
import net.osmand.plus.routing.RouteProvider.GPXRouteParamsBuilder;
import net.osmand.plus.routing.RoutingHelper;
@ -695,6 +696,21 @@ public class MapActivityActions implements DialogProvider {
}
}).createItem());
optionsMenuHelper.addItem(new ContextMenuItem.ItemBuilder().setTitleId(R.string.measurement_tool, mapActivity)
.setIcon(R.drawable.ic_action_ruler)
.setListener(new ContextMenuAdapter.ItemClickListener() {
@Override
public boolean onContextMenuClick(ArrayAdapter<ContextMenuItem> adapter, int itemId, int position, boolean isChecked) {
MeasurementToolFragment fragment = new MeasurementToolFragment();
mapActivity.getSupportFragmentManager()
.beginTransaction()
.add(R.id.bottomFragmentContainer, fragment, MeasurementToolFragment.TAG)
.addToBackStack(MeasurementToolFragment.TAG)
.commitAllowingStateLoss();
return true;
}
}).createItem());
optionsMenuHelper.addItem(new ItemBuilder().setTitleId(R.string.get_directions, mapActivity)
.setIcon(R.drawable.ic_action_gdirections_dark)
.setListener(new ContextMenuAdapter.ItemClickListener() {

View file

@ -28,6 +28,7 @@ import net.osmand.plus.R;
import net.osmand.plus.SQLiteTileSource;
import net.osmand.plus.activities.MapActivity.ShowQuickSearchMode;
import net.osmand.plus.helpers.GpxUiHelper;
import net.osmand.plus.measurementtool.MeasurementToolLayer;
import net.osmand.plus.poi.PoiFiltersHelper;
import net.osmand.plus.poi.PoiUIFilter;
import net.osmand.plus.quickaction.QuickActionRegistry;
@ -88,6 +89,7 @@ public class MapActivityLayers {
private DownloadedRegionsLayer downloadedRegionsLayer;
private MapWidgetRegistry mapWidgetRegistry;
private QuickActionRegistry quickActionRegistry;
private MeasurementToolLayer measurementToolLayer;
private StateChangedListener<Integer> transparencyListener;
@ -148,6 +150,9 @@ public class MapActivityLayers {
// 4. favorites layer
mFavouritesLayer = new FavouritesLayer();
mapView.addLayer(mFavouritesLayer, 4);
// 4.6 measurement tool layer
measurementToolLayer = new MeasurementToolLayer();
mapView.addLayer(measurementToolLayer, 4.6f);
// 5. transport layer
transportStopsLayer = new TransportStopsLayer(activity);
mapView.addLayer(transportStopsLayer, 5);
@ -583,6 +588,10 @@ public class MapActivityLayers {
return mFavouritesLayer;
}
public MeasurementToolLayer getMeasurementToolLayer() {
return measurementToolLayer;
}
public MapTextLayer getMapTextLayer() {
return mapTextLayer;
}

View file

@ -198,8 +198,7 @@ public class ShareDialog {
builder.setPositiveButton(activity.getString(R.string.shared_string_yes), new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(Version.marketPrefix((OsmandApplication) activity.getApplication())
+ ZXING_BARCODE_SCANNER_COMPONENT));
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(Version.getUrlWithUtmRef((OsmandApplication) activity.getApplication(), ZXING_BARCODE_SCANNER_COMPONENT)));
try {
activity.startActivity(intent);
} catch (ActivityNotFoundException e) {

View file

@ -26,7 +26,6 @@ import net.osmand.AndroidUtils;
import net.osmand.plus.R;
import net.osmand.plus.Version;
import net.osmand.plus.activities.MapActivity;
import net.osmand.plus.views.OsmandMapTileView;
public class StartGPSStatus extends OsmAndAction {
@ -178,7 +177,7 @@ public class StartGPSStatus extends OsmAndAction {
builder.setPositiveButton(mapActivity.getString(R.string.shared_string_yes), new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(Version.marketPrefix(getMyApplication()) + g.appName));
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(Version.getUrlWithUtmRef(getMyApplication(), g.appName)));
try {
mapActivity.startActivity(intent);
} catch (ActivityNotFoundException e) {

View file

@ -1,6 +1,7 @@
package net.osmand.plus.base;
import android.content.Context;
import android.os.AsyncTask;
import android.support.v4.util.Pair;
import android.view.WindowManager;
@ -150,28 +151,45 @@ public class MapViewTrackingUtilities implements OsmAndLocationListener, IMapLoc
return movingToMyLocation;
}
private void detectDrivingRegion(final LatLon latLon) {
new AsyncTask<LatLon, Void, BinaryMapDataObject>() {
@Override
protected BinaryMapDataObject doInBackground(LatLon... latLons) {
try {
if (latLons != null && latLons.length > 0) {
return app.getRegions().findBinaryMapDataObject(latLons[0]);
}
} catch (IOException e) {
// ignore
}
return null;
}
@Override
protected void onPostExecute(BinaryMapDataObject o) {
if (o != null) {
String fullName = app.getRegions().getFullName(o);
WorldRegion worldRegion = app.getRegions().getRegionData(fullName);
if (worldRegion != null) {
app.setupDrivingRegion(worldRegion);
}
}
}
}.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR, latLon);
}
@Override
public void updateLocation(Location location) {
myLocation = location;
showViewAngle = false;
if (location != null) {
locationProvider = location.getProvider();
if (settings.DRIVING_REGION_AUTOMATIC.get() && !drivingRegionUpdated) {
try {
BinaryMapDataObject o = app.getRegions().findBinaryMapDataObject(
new LatLon(location.getLatitude(), location.getLongitude()));
if (o != null) {
String fullName = app.getRegions().getFullName(o);
WorldRegion worldRegion = app.getRegions().getRegionData(fullName);
if (worldRegion != null) {
app.setupDrivingRegion(worldRegion);
}
}
drivingRegionUpdated = true;
} catch (IOException e) {
// ignore
}
if (settings.DRIVING_REGION_AUTOMATIC.get() && !drivingRegionUpdated && !app.isApplicationInitializing()) {
drivingRegionUpdated = true;
detectDrivingRegion(new LatLon(location.getLatitude(), location.getLongitude()));
}
}
if (mapView != null) {

View file

@ -86,7 +86,7 @@ public class DashRateUsFragment extends DashBaseFragment {
return;
case USER_LIKES_APP:
settings.RATE_US_STATE.set(RateUsBottomSheetDialog.RateUsState.LIKED);
Uri uri = Uri.parse(Version.marketPrefix(getMyApplication()) + getActivity().getPackageName());
Uri uri = Uri.parse(Version.getUrlWithUtmRef(getMyApplication(), getActivity().getPackageName()));
Intent goToMarket = new Intent(Intent.ACTION_VIEW, uri);
startActivity(goToMarket);
break;

View file

@ -115,7 +115,7 @@ public class RateUsBottomSheetDialog extends BottomSheetDialogFragment {
return;
case USER_LIKES_APP:
settings.RATE_US_STATE.set(RateUsBottomSheetDialog.RateUsState.LIKED);
Uri uri = Uri.parse(Version.marketPrefix(getMyApplication()) + getActivity().getPackageName());
Uri uri = Uri.parse(Version.getUrlWithUtmRef(getMyApplication(), getActivity().getPackageName()));
Intent goToMarket = new Intent(Intent.ACTION_VIEW, uri);
startActivity(goToMarket);
break;

View file

@ -248,7 +248,7 @@ public class DownloadActivity extends AbstractDownloadActivity implements Downlo
} else {
app.logEvent(this, "paid_version_redirect");
Intent intent = new Intent(Intent.ACTION_VIEW,
Uri.parse(Version.marketPrefix(app) + "net.osmand.plus"));
Uri.parse(Version.getUrlWithUtmRef(app, "net.osmand.plus")));
try {
startActivity(intent);
} catch (ActivityNotFoundException e) {

View file

@ -381,7 +381,7 @@ public class DownloadIndexesThread {
builder.setPositiveButton(R.string.button_upgrade_osmandplus, new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://search?q=pname:net.osmand.plus"));
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(Version.getUrlWithUtmRef(app, "net.osmand.plus")));
try {
ctx.startActivity(intent);
} catch (ActivityNotFoundException e) {

View file

@ -224,8 +224,7 @@ public class DownloadValidationManager {
@Override
public void onClick(DialogInterface dialog, int which) {
Intent intent = new Intent(Intent.ACTION_VIEW,
Uri.parse(Version.marketPrefix(getMyApplication())
+ "net.osmand.plus"));
Uri.parse(Version.getUrlWithUtmRef(getMyApplication(), "net.osmand.plus")));
try {
startActivity(intent);
} catch (ActivityNotFoundException e) {

View file

@ -17,6 +17,7 @@ import android.widget.ImageView;
import android.widget.TextView;
import android.widget.Toast;
import net.osmand.IProgress;
import net.osmand.plus.OnDismissDialogFragmentListener;
import net.osmand.plus.OsmandApplication;
import net.osmand.plus.OsmandSettings;
@ -24,6 +25,7 @@ import net.osmand.plus.R;
import net.osmand.plus.base.BottomSheetDialogFragment;
import net.osmand.plus.dashboard.DashChooseAppDirFragment;
import net.osmand.plus.download.DownloadActivity;
import net.osmand.plus.download.DownloadIndexesThread;
import java.io.File;
@ -196,11 +198,22 @@ public class DataStoragePlaceDialogFragment extends BottomSheetDialogFragment {
return sz;
}
private void checkAssets() {
getMyApplication().getResourceManager().checkAssets(IProgress.EMPTY_PROGRESS, true);
}
private void updateDownloadIndexes() {
DownloadIndexesThread downloadIndexesThread = getMyApplication().getDownloadThread();
downloadIndexesThread.runReloadIndexFilesSilent();
}
private View.OnClickListener deviceMemoryOnClickListener =
new View.OnClickListener() {
@Override
public void onClick(View v) {
saveFilesLocation(deviceStorageType, deviceStorage, getActivity());
checkAssets();
updateDownloadIndexes();
isInterestedInFirstTime = false;
dismiss();
}
@ -211,6 +224,8 @@ public class DataStoragePlaceDialogFragment extends BottomSheetDialogFragment {
@Override
public void onClick(View v) {
saveFilesLocation(sharedStorageType, sharedStorage, getActivity());
checkAssets();
updateDownloadIndexes();
isInterestedInFirstTime = false;
dismiss();
}
@ -221,6 +236,8 @@ public class DataStoragePlaceDialogFragment extends BottomSheetDialogFragment {
@Override
public void onClick(View v) {
boolean res = saveFilesLocation(cardStorageType, cardStorage, getActivity());
checkAssets();
updateDownloadIndexes();
isInterestedInFirstTime = false;
if (res) {
dismiss();

View file

@ -147,7 +147,7 @@ public class DiscountHelper {
int i = url.indexOf("osmand-market-app:");
if (i != -1) {
String appName = url.substring(i + 18);
return Version.marketPrefix(app) + appName;
return Version.getUrlWithUtmRef(app, appName);
}
}
return url;

View file

@ -305,6 +305,9 @@ public class MapContextMenu extends MenuTitleController implements StateChangedL
appModeChanged = false;
if (needAcquireMenuController) {
if (menuController != null) {
menuController.setMapContextMenu(null);
}
if (!acquireMenuController(restorePrevious)) {
active = false;
clearSelectedObject(object);
@ -380,6 +383,13 @@ public class MapContextMenu extends MenuTitleController implements StateChangedL
}
}
public void rebuildMenu() {
WeakReference<MapContextMenuFragment> fragmentRef = findMenuFragment();
if (fragmentRef != null) {
fragmentRef.get().rebuildMenu();
}
}
public void showOrUpdate(LatLon latLon, PointDescription pointDescription, Object object) {
if (isVisible() && this.object != null && this.object.equals(object)) {
update(latLon, pointDescription, object);
@ -526,6 +536,7 @@ public class MapContextMenu extends MenuTitleController implements StateChangedL
}
menuController = MenuController.getMenuController(mapActivity, latLon, pointDescription, object, MenuType.STANDARD);
if (menuController.setActive(true)) {
menuController.setMapContextMenu(this);
if (menuData != null && (object != menuData.getObject())
&& (menuController.hasBackAction() || menuData.hasBackAction())) {
historyStack.add(menuData);
@ -598,17 +609,20 @@ public class MapContextMenu extends MenuTitleController implements StateChangedL
public void onSingleTapOnMap() {
if (menuController == null || !menuController.handleSingleTapOnMap()) {
hide();
if (mapActivity.getMapLayers().getMapQuickActionLayer().isLayerOn())
updateMapCenter(null);
close();
if (mapActivity.getMapLayers().getMapQuickActionLayer().isLayerOn()) {
mapActivity.getMapLayers().getMapQuickActionLayer().refreshLayer();
}
}
}
@Override
public void onSearchAddressDone() {
WeakReference<MapContextMenuFragment> fragmentRef = findMenuFragment();
if (fragmentRef != null)
if (fragmentRef != null) {
fragmentRef.get().refreshTitle();
}
if (searchDoneAction != null) {
if (searchDoneAction.dlg != null) {

View file

@ -67,12 +67,6 @@ public class MapContextMenuFragment extends Fragment implements DownloadEvents {
ImageView fabView;
private MapContextMenu menu;
private TitleButtonController leftTitleButtonController;
private TitleButtonController rightTitleButtonController;
private TitleButtonController topRightTitleButtonController;
private TitleButtonController leftDownloadButtonController;
private TitleButtonController rightDownloadButtonController;
private TitleProgressController titleProgressController;
private int menuTopViewHeight;
private int menuTopShadowHeight;
@ -107,6 +101,7 @@ public class MapContextMenuFragment extends Fragment implements DownloadEvents {
private float skipHalfScreenStateLimit;
private int screenOrientation;
private boolean created;
@TargetApi(Build.VERSION_CODES.HONEYCOMB)
@Override
@ -130,14 +125,6 @@ public class MapContextMenuFragment extends Fragment implements DownloadEvents {
nightMode = menu.isNightMode();
mainView = view.findViewById(R.id.context_menu_main);
leftTitleButtonController = menu.getLeftTitleButtonController();
rightTitleButtonController = menu.getRightTitleButtonController();
topRightTitleButtonController = menu.getTopRightTitleButtonController();
leftDownloadButtonController = menu.getLeftDownloadButtonController();
rightDownloadButtonController = menu.getRightDownloadButtonController();
titleProgressController = menu.getTitleProgressController();
map = getMapActivity().getMapView();
RotatedTileBox box = map.getCurrentRotatedTileBox().copy();
customMapCenter = menu.getMapCenter() != null;
@ -162,71 +149,77 @@ public class MapContextMenuFragment extends Fragment implements DownloadEvents {
// Left title button
final Button leftTitleButton = (Button) view.findViewById(R.id.title_button);
if (leftTitleButtonController != null) {
leftTitleButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
leftTitleButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
TitleButtonController leftTitleButtonController = menu.getLeftTitleButtonController();
if (leftTitleButtonController != null) {
leftTitleButtonController.buttonPressed();
}
});
}
}
});
// Right title button
final Button rightTitleButton = (Button) view.findViewById(R.id.title_button_right);
if (rightTitleButtonController != null) {
rightTitleButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
rightTitleButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
TitleButtonController rightTitleButtonController = menu.getRightTitleButtonController();
if (rightTitleButtonController != null) {
rightTitleButtonController.buttonPressed();
}
});
}
}
});
// Left download button
final Button leftDownloadButton = (Button) view.findViewById(R.id.download_button_left);
if (leftDownloadButtonController != null) {
leftDownloadButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
leftDownloadButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
TitleButtonController leftDownloadButtonController = menu.getLeftDownloadButtonController();
if (leftDownloadButtonController != null) {
leftDownloadButtonController.buttonPressed();
}
});
}
}
});
// Right download button
final Button rightDownloadButton = (Button) view.findViewById(R.id.download_button_right);
if (rightDownloadButtonController != null) {
rightDownloadButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
rightDownloadButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
TitleButtonController rightDownloadButtonController = menu.getRightDownloadButtonController();
if (rightDownloadButtonController != null) {
rightDownloadButtonController.buttonPressed();
}
});
}
}
});
// Top Right title button
final Button topRightTitleButton = (Button) view.findViewById(R.id.title_button_top_right);
if (topRightTitleButtonController != null) {
topRightTitleButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
topRightTitleButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
TitleButtonController topRightTitleButtonController = menu.getTopRightTitleButtonController();
if (topRightTitleButtonController != null) {
topRightTitleButtonController.buttonPressed();
}
});
}
}
});
// Progress bar
if (titleProgressController != null) {
final ImageView progressButton = (ImageView) view.findViewById(R.id.progressButton);
progressButton.setImageDrawable(iconsCache.getIcon(R.drawable.ic_action_remove_dark,
!nightMode ? R.color.icon_color : R.color.dashboard_subheader_text_dark));
progressButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
final ImageView progressButton = (ImageView) view.findViewById(R.id.progressButton);
progressButton.setImageDrawable(iconsCache.getIcon(R.drawable.ic_action_remove_dark,
!nightMode ? R.color.icon_color : R.color.dashboard_subheader_text_dark));
progressButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
TitleProgressController titleProgressController = menu.getTitleProgressController();
if (titleProgressController != null) {
titleProgressController.buttonPressed();
}
});
}
}
});
menu.updateData();
updateButtonsAndProgress();
@ -471,6 +464,7 @@ public class MapContextMenuFragment extends Fragment implements DownloadEvents {
//getMapActivity().getMapLayers().getMapControlsLayer().setControlsClickable(false);
created = true;
return view;
}
@ -583,6 +577,13 @@ public class MapContextMenuFragment extends Fragment implements DownloadEvents {
private void updateButtonsAndProgress() {
if (view != null) {
TitleButtonController leftTitleButtonController = menu.getLeftTitleButtonController();
TitleButtonController rightTitleButtonController = menu.getRightTitleButtonController();
TitleButtonController topRightTitleButtonController = menu.getTopRightTitleButtonController();
TitleButtonController leftDownloadButtonController = menu.getLeftDownloadButtonController();
TitleButtonController rightDownloadButtonController = menu.getRightDownloadButtonController();
TitleProgressController titleProgressController = menu.getTitleProgressController();
// Title buttons
boolean showTitleButtonsContainer = (leftTitleButtonController != null || rightTitleButtonController != null);
final View titleButtonsContainer = view.findViewById(R.id.title_button_container);
@ -848,12 +849,39 @@ public class MapContextMenuFragment extends Fragment implements DownloadEvents {
line2LineHeight = line2.getLineHeight();
line2MeasuredHeight = line2.getMeasuredHeight();
}
int dp16 = dpToPx(16f);
int titleButtonHeight = 0;
View titleButtonContainer = view.findViewById(R.id.title_button_container);
if (titleButtonContainer.getVisibility() == View.VISIBLE) {
titleButtonHeight = titleButtonContainer.getMeasuredHeight() - dp16;
if (titleButtonHeight < 0) {
titleButtonHeight = 0;
}
}
int downloadButtonsHeight = 0;
View downloadButtonsContainer = view.findViewById(R.id.download_buttons_container);
if (downloadButtonsContainer.getVisibility() == View.VISIBLE) {
downloadButtonsHeight = downloadButtonsContainer.getMeasuredHeight() - dp16;
if (downloadButtonsHeight < 0) {
downloadButtonsHeight = 0;
}
}
int titleProgressHeight = 0;
View titleProgressContainer = view.findViewById(R.id.title_progress_container);
if (titleProgressContainer.getVisibility() == View.VISIBLE) {
titleProgressHeight = titleProgressContainer.getMeasuredHeight() - dp16;
if (titleProgressHeight < 0) {
titleProgressHeight = 0;
}
}
if (menuTopViewHeight != 0) {
int titleHeight = line1.getLineCount() * line1.getLineHeight() + line2LineCount * line2LineHeight + menuTitleTopBottomPadding;
if (titleHeight < line1.getMeasuredHeight() + line2MeasuredHeight) {
titleHeight = line1.getMeasuredHeight() + line2MeasuredHeight;
}
newMenuTopViewHeight = menuTopViewHeightExcludingTitle + titleHeight;
newMenuTopViewHeight = menuTopViewHeightExcludingTitle + titleHeight + titleButtonHeight + downloadButtonsHeight + titleProgressHeight;
dy = Math.max(0, newMenuTopViewHeight - menuTopViewHeight - (newMenuTopShadowAllHeight - menuTopShadowAllHeight));
} else {
menuTopViewHeightExcludingTitle = newMenuTopViewHeight - line1.getMeasuredHeight() - line2MeasuredHeight;
@ -1268,9 +1296,11 @@ public class MapContextMenuFragment extends Fragment implements DownloadEvents {
}
public void updateMenu() {
menu.updateData();
updateButtonsAndProgress();
runLayoutListener();
if (created) {
menu.updateData();
updateButtonsAndProgress();
runLayoutListener();
}
}
private MapActivity getMapActivity() {

View file

@ -1,6 +1,7 @@
package net.osmand.plus.mapcontextmenu;
import android.graphics.drawable.Drawable;
import android.os.AsyncTask;
import android.support.annotation.NonNull;
import android.view.View;
import android.view.View.OnClickListener;
@ -86,6 +87,7 @@ public abstract class MenuController extends BaseMenuController {
MULTI_LINE
}
protected MapContextMenu mapContextMenu;
protected MenuBuilder builder;
private int currentMenuState;
private MenuType menuType = MenuType.STANDARD;
@ -117,6 +119,10 @@ public abstract class MenuController extends BaseMenuController {
this.builder.setLight(isLight());
}
public void setMapContextMenu(MapContextMenu mapContextMenu) {
this.mapContextMenu = mapContextMenu;
}
public void build(View rootView) {
for (OsmandPlugin plugin : OsmandPlugin.getEnabledPlugins()) {
if (plugin.isMenuControllerSupported(this.getClass())) {
@ -531,114 +537,137 @@ public abstract class MenuController extends BaseMenuController {
}
}
public void buildMapDownloadButton(LatLon latLon) {
int point31x = MapUtils.get31TileNumberX(latLon.getLongitude());
int point31y = MapUtils.get31TileNumberY(latLon.getLatitude());
public void buildMapDownloadButton(final LatLon latLon) {
new AsyncTask<Void, Void, BinaryMapDataObject>() {
ResourceManager rm = getMapActivity().getMyApplication().getResourceManager();
OsmandRegions osmandRegions = rm.getOsmandRegions();
List<BinaryMapDataObject> mapDataObjects = null;
try {
mapDataObjects = osmandRegions.queryBbox(point31x, point31x, point31y, point31y);
} catch (IOException e) {
e.printStackTrace();
}
if (mapDataObjects != null) {
Iterator<BinaryMapDataObject> it = mapDataObjects.iterator();
while (it.hasNext()) {
BinaryMapDataObject o = it.next();
if (o.getTypes() != null) {
boolean isRegion = true;
for (int i = 0; i < o.getTypes().length; i++) {
TagValuePair tp = o.getMapIndex().decodeType(o.getTypes()[i]);
if ("boundary".equals(tp.value)) {
isRegion = false;
break;
}
}
if (!isRegion || !osmandRegions.contain(o, point31x, point31y)) {
it.remove();
}
}
}
ResourceManager rm;
OsmandRegions osmandRegions;
String selectedFullName = "";
double smallestArea = -1;
downloadMapDataObject = null;
for (BinaryMapDataObject o : mapDataObjects) {
String downloadName = osmandRegions.getDownloadName(o);
if (!Algorithms.isEmpty(downloadName)) {
boolean downloaded = checkIfObjectDownloaded(rm, downloadName);
if (downloaded) {
downloadMapDataObject = null;
break;
} else {
String fullName = osmandRegions.getFullName(o);
WorldRegion region = osmandRegions.getRegionData(fullName);
if (region != null && region.isRegionMapDownload()) {
double area = OsmandRegions.getArea(o);
if (smallestArea == -1) {
smallestArea = area;
selectedFullName = fullName;
downloadMapDataObject = o;
} else if (area < smallestArea) {
smallestArea = area;
selectedFullName = fullName;
downloadMapDataObject = o;
@Override
protected void onPreExecute() {
rm = getMapActivity().getMyApplication().getResourceManager();
osmandRegions = rm.getOsmandRegions();
}
@Override
protected BinaryMapDataObject doInBackground(Void... voids) {
int point31x = MapUtils.get31TileNumberX(latLon.getLongitude());
int point31y = MapUtils.get31TileNumberY(latLon.getLatitude());
List<BinaryMapDataObject> mapDataObjects = null;
try {
mapDataObjects = osmandRegions.queryBbox(point31x, point31x, point31y, point31y);
} catch (IOException e) {
e.printStackTrace();
}
BinaryMapDataObject binaryMapDataObject = null;
if (mapDataObjects != null) {
Iterator<BinaryMapDataObject> it = mapDataObjects.iterator();
while (it.hasNext()) {
BinaryMapDataObject o = it.next();
if (o.getTypes() != null) {
boolean isRegion = true;
for (int i = 0; i < o.getTypes().length; i++) {
TagValuePair tp = o.getMapIndex().decodeType(o.getTypes()[i]);
if ("boundary".equals(tp.value)) {
isRegion = false;
break;
}
}
if (!isRegion || !osmandRegions.contain(o, point31x, point31y)) {
it.remove();
}
}
}
double smallestArea = -1;
for (BinaryMapDataObject o : mapDataObjects) {
String downloadName = osmandRegions.getDownloadName(o);
if (!Algorithms.isEmpty(downloadName)) {
boolean downloaded = checkIfObjectDownloaded(rm, downloadName);
if (downloaded) {
binaryMapDataObject = null;
break;
} else {
String fullName = osmandRegions.getFullName(o);
WorldRegion region = osmandRegions.getRegionData(fullName);
if (region != null && region.isRegionMapDownload()) {
double area = OsmandRegions.getArea(o);
if (smallestArea == -1) {
smallestArea = area;
selectedFullName = fullName;
binaryMapDataObject = o;
} else if (area < smallestArea) {
smallestArea = area;
selectedFullName = fullName;
binaryMapDataObject = o;
}
}
}
}
}
}
return binaryMapDataObject;
}
downloaded = downloadMapDataObject == null;
if (!downloaded) {
downloadThread = getMapActivity().getMyApplication().getDownloadThread();
downloadRegion = osmandRegions.getRegionData(selectedFullName);
if (downloadRegion != null && downloadRegion.isRegionMapDownload()) {
List<IndexItem> indexItems = downloadThread.getIndexes().getIndexItems(downloadRegion);
for (IndexItem item : indexItems) {
if (item.getType() == DownloadActivityType.NORMAL_FILE
&& (item.isDownloaded() || downloadThread.isDownloading(item))) {
indexItem = item;
}
}
}
leftDownloadButtonController = new TitleButtonController() {
@Override
public void buttonPressed() {
if (indexItem != null) {
if (indexItem.getType() == DownloadActivityType.NORMAL_FILE) {
new DownloadValidationManager(getMapActivity().getMyApplication())
.startDownload(getMapActivity(), indexItem);
@Override
protected void onPostExecute(BinaryMapDataObject binaryMapDataObject) {
downloadMapDataObject = binaryMapDataObject;
downloaded = downloadMapDataObject == null;
if (!downloaded) {
downloadThread = getMapActivity().getMyApplication().getDownloadThread();
downloadRegion = osmandRegions.getRegionData(selectedFullName);
if (downloadRegion != null && downloadRegion.isRegionMapDownload()) {
List<IndexItem> indexItems = downloadThread.getIndexes().getIndexItems(downloadRegion);
for (IndexItem item : indexItems) {
if (item.getType() == DownloadActivityType.NORMAL_FILE
&& (item.isDownloaded() || downloadThread.isDownloading(item))) {
indexItem = item;
}
}
}
};
leftDownloadButtonController.caption =
downloadRegion != null ? downloadRegion.getLocaleName() : getMapActivity().getString(R.string.shared_string_download);
leftDownloadButtonController.leftIconId = R.drawable.ic_action_import;
titleProgressController = new TitleProgressController() {
@Override
public void buttonPressed() {
if (indexItem != null) {
downloadThread.cancelDownload(indexItem);
leftDownloadButtonController = new TitleButtonController() {
@Override
public void buttonPressed() {
if (indexItem != null) {
if (indexItem.getType() == DownloadActivityType.NORMAL_FILE) {
new DownloadValidationManager(getMapActivity().getMyApplication())
.startDownload(getMapActivity(), indexItem);
}
}
}
};
leftDownloadButtonController.caption =
downloadRegion != null ? downloadRegion.getLocaleName() : getMapActivity().getString(R.string.shared_string_download);
leftDownloadButtonController.leftIconId = R.drawable.ic_action_import;
titleProgressController = new TitleProgressController() {
@Override
public void buttonPressed() {
if (indexItem != null) {
downloadThread.cancelDownload(indexItem);
}
}
};
if (!downloadThread.getIndexes().isDownloadedFromInternet) {
if (getMapActivity().getMyApplication().getSettings().isInternetConnectionAvailable()) {
downloadThread.runReloadIndexFiles();
}
}
};
if (!downloadThread.getIndexes().isDownloadedFromInternet) {
if (getMapActivity().getMyApplication().getSettings().isInternetConnectionAvailable()) {
downloadThread.runReloadIndexFiles();
if (mapContextMenu != null) {
mapContextMenu.updateMenuUI();
}
}
updateData();
}
}
}.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
}
private boolean checkIfObjectDownloaded(ResourceManager rm, String downloadName) {

View file

@ -109,7 +109,7 @@ public class ContextMenuCardDialogFragment extends Fragment {
fragment.dialog = menu;
menu.getMapActivity().getSupportFragmentManager().beginTransaction()
.replace(R.id.topFragmentContainer, fragment, TAG)
.addToBackStack(TAG).commit();
.addToBackStack(TAG).commitAllowingStateLoss();
}
public void dismiss() {

View file

@ -35,7 +35,7 @@ public class MapillaryInstallDialogFragment extends DialogFragment {
@Override
public void onClick(DialogInterface dialog, int which) {
dialog.dismiss();
MapillaryPlugin.installMapillary(mapActivity.getMyApplication());
MapillaryPlugin.installMapillary(mapActivity, mapActivity.getMyApplication());
}
});

View file

@ -2,6 +2,7 @@ package net.osmand.plus.mapillary;
import android.app.Activity;
import android.content.ActivityNotFoundException;
import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
@ -23,6 +24,7 @@ import net.osmand.plus.OsmandApplication;
import net.osmand.plus.OsmandPlugin;
import net.osmand.plus.OsmandSettings;
import net.osmand.plus.R;
import net.osmand.plus.Version;
import net.osmand.plus.activities.MapActivity;
import net.osmand.plus.activities.MapActivityLayers;
import net.osmand.plus.base.BottomSheetDialogFragment;
@ -34,6 +36,7 @@ import net.osmand.plus.views.mapwidgets.MapWidgetRegistry.MapWidgetRegInfo;
import net.osmand.plus.views.mapwidgets.TextInfoWidget;
import net.osmand.util.Algorithms;
import java.lang.reflect.Method;
import java.text.MessageFormat;
import java.util.List;
@ -235,8 +238,9 @@ public class MapillaryPlugin extends OsmandPlugin {
return success;
}
public static boolean installMapillary(OsmandApplication app) {
boolean success = execInstall(app, "market://search?q=pname:" + MAPILLARY_PACKAGE_ID);
public static boolean installMapillary(Activity activity, OsmandApplication app) {
app.logEvent(activity, "install_mapillary");
boolean success = execInstall(app, Version.getUrlWithUtmRef(app, MAPILLARY_PACKAGE_ID));
if (!success) {
success = execInstall(app, "https://play.google.com/store/apps/details?id=" + MAPILLARY_PACKAGE_ID);
}

View file

@ -0,0 +1,149 @@
package net.osmand.plus.measurementtool;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.view.ContextThemeWrapper;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import android.widget.TextView;
import net.osmand.AndroidUtils;
import net.osmand.plus.IconsCache;
import net.osmand.plus.R;
import net.osmand.plus.activities.MapActivity;
public class MeasurementToolFragment extends Fragment {
public static final String TAG = "MeasurementToolFragment";
private TextView distanceTv;
private TextView pointsTv;
private String pointsSt;
private boolean wasCollapseButtonVisible;
@Nullable
@Override
public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
MapActivity mapActivity = (MapActivity) getActivity();
final MeasurementToolLayer measurementLayer = mapActivity.getMapLayers().getMeasurementToolLayer();
IconsCache iconsCache = mapActivity.getMyApplication().getIconsCache();
final boolean nightMode = mapActivity.getMyApplication().getDaynightHelper().isNightModeForMapControls();
final int themeRes = nightMode ? R.style.OsmandDarkTheme : R.style.OsmandLightTheme;
pointsSt = mapActivity.getString(R.string.points).toLowerCase();
View view = View.inflate(new ContextThemeWrapper(getContext(), themeRes), R.layout.fragment_measurement_tool, null);
final View mainView = view.findViewById(R.id.main_view);
AndroidUtils.setBackground(mapActivity, mainView, nightMode, R.drawable.bg_bottom_menu_light, R.drawable.bg_bottom_menu_dark);
distanceTv = (TextView) mainView.findViewById(R.id.measurement_distance_text_view);
pointsTv = (TextView) mainView.findViewById(R.id.measurement_points_text_view);
((ImageView) mainView.findViewById(R.id.ruler_icon))
.setImageDrawable(iconsCache.getIcon(R.drawable.ic_action_ruler, R.color.color_myloc_distance));
((ImageView) mainView.findViewById(R.id.up_down_icon))
.setImageDrawable(iconsCache.getThemedIcon(R.drawable.ic_action_arrow_up));
((ImageView) mainView.findViewById(R.id.previous_dot_icon))
.setImageDrawable(iconsCache.getThemedIcon(R.drawable.ic_action_undo_dark));
((ImageView) mainView.findViewById(R.id.next_dot_icon))
.setImageDrawable(iconsCache.getThemedIcon(R.drawable.ic_action_redo_dark));
mainView.findViewById(R.id.add_point_button).setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
measurementLayer.addPointOnClick();
updateText();
}
});
enterMeasurementMode();
return view;
}
@Override
public void onDestroyView() {
super.onDestroyView();
exitMeasurementMode();
}
private MapActivity getMapActivity() {
return (MapActivity) getActivity();
}
private MeasurementToolLayer getMeasurementLayer() {
MapActivity mapActivity = getMapActivity();
if (mapActivity != null) {
return mapActivity.getMapLayers().getMeasurementToolLayer();
}
return null;
}
private void updateText() {
MeasurementToolLayer measurementLayer = getMeasurementLayer();
if (measurementLayer != null) {
distanceTv.setText(measurementLayer.getDistanceSt() + ",");
pointsTv.setText(pointsSt + ": " + measurementLayer.getPointsCount());
}
}
private void enterMeasurementMode() {
MapActivity mapActivity = getMapActivity();
MeasurementToolLayer measurementLayer = getMeasurementLayer();
if (mapActivity != null && measurementLayer != null) {
measurementLayer.setInMeasurementMode(true);
mapActivity.refreshMap();
mapActivity.disableDrawer();
mark(View.INVISIBLE, R.id.map_left_widgets_panel, R.id.map_right_widgets_panel, R.id.map_center_info);
mark(View.GONE, R.id.map_route_info_button, R.id.map_menu_button, R.id.map_compass_button, R.id.map_layers_button,
R.id.map_search_button, R.id.map_quick_actions_button);
View collapseButton = mapActivity.findViewById(R.id.map_collapse_button);
if (collapseButton != null && collapseButton.getVisibility() == View.VISIBLE) {
wasCollapseButtonVisible = true;
collapseButton.setVisibility(View.INVISIBLE);
} else {
wasCollapseButtonVisible = false;
}
updateText();
}
}
private void exitMeasurementMode() {
MapActivity mapActivity = getMapActivity();
MeasurementToolLayer measurementLayer = getMeasurementLayer();
if (mapActivity != null && measurementLayer != null) {
measurementLayer.setInMeasurementMode(false);
mapActivity.refreshMap();
mapActivity.enableDrawer();
mark(View.VISIBLE, R.id.map_left_widgets_panel, R.id.map_right_widgets_panel, R.id.map_center_info,
R.id.map_route_info_button, R.id.map_menu_button, R.id.map_compass_button, R.id.map_layers_button,
R.id.map_search_button, R.id.map_quick_actions_button);
View collapseButton = mapActivity.findViewById(R.id.map_collapse_button);
if (collapseButton != null && wasCollapseButtonVisible) {
collapseButton.setVisibility(View.VISIBLE);
}
measurementLayer.clearPoints();
}
}
private void mark(int status, int... widgets) {
MapActivity mapActivity = getMapActivity();
if (mapActivity != null) {
for (int widget : widgets) {
View v = mapActivity.findViewById(widget);
if (v != null) {
v.setVisibility(status);
}
}
}
}
}

View file

@ -0,0 +1,149 @@
package net.osmand.plus.measurementtool;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.Paint;
import android.graphics.Path;
import net.osmand.data.LatLon;
import net.osmand.data.QuadPoint;
import net.osmand.data.RotatedTileBox;
import net.osmand.plus.GPXUtilities.WptPt;
import net.osmand.plus.OsmAndFormatter;
import net.osmand.plus.R;
import net.osmand.plus.views.OsmandMapLayer;
import net.osmand.plus.views.OsmandMapTileView;
import net.osmand.util.MapUtils;
import java.util.LinkedList;
import gnu.trove.list.array.TIntArrayList;
public class MeasurementToolLayer extends OsmandMapLayer {
private OsmandMapTileView view;
private boolean inMeasurementMode;
private LinkedList<WptPt> measurementPoints = new LinkedList<>();
private Bitmap centerIconDay;
private Bitmap centerIconNight;
private Bitmap pointIcon;
private Paint bitmapPaint;
private RenderingLineAttributes lineAttrs = new RenderingLineAttributes("rulerLine");
private Path path = new Path();
private int marginX;
private int marginY;
private TIntArrayList tx = new TIntArrayList();
private TIntArrayList ty = new TIntArrayList();
@Override
public void initLayer(OsmandMapTileView view) {
this.view = view;
centerIconDay = BitmapFactory.decodeResource(view.getResources(), R.drawable.map_ruler_center_day);
centerIconNight = BitmapFactory.decodeResource(view.getResources(), R.drawable.map_ruler_center_night);
pointIcon = BitmapFactory.decodeResource(view.getResources(), R.drawable.map_pedestrian_location);
bitmapPaint = new Paint();
bitmapPaint.setAntiAlias(true);
bitmapPaint.setDither(true);
bitmapPaint.setFilterBitmap(true);
marginY = pointIcon.getHeight() / 2;
marginX = pointIcon.getWidth() / 2;
}
public boolean isInMeasurementMode() {
return inMeasurementMode;
}
void setInMeasurementMode(boolean inMeasurementMode) {
this.inMeasurementMode = inMeasurementMode;
}
int getPointsCount() {
return measurementPoints.size();
}
String getDistanceSt() {
float dist = 0;
if (measurementPoints.size() > 0) {
for (int i = 1; i < measurementPoints.size(); i++) {
dist += MapUtils.getDistance(measurementPoints.get(i - 1).lat, measurementPoints.get(i - 1).lon,
measurementPoints.get(i).lat, measurementPoints.get(i).lon);
}
}
return OsmAndFormatter.getFormattedDistance(dist, view.getApplication());
}
void clearPoints() {
measurementPoints.clear();
}
@Override
public void onDraw(Canvas canvas, RotatedTileBox tb, DrawSettings settings) {
if (inMeasurementMode) {
lineAttrs.updatePaints(view, settings, tb);
drawCenterIcon(canvas, tb, tb.getCenterPixelPoint(), settings.isNightMode());
if (measurementPoints.size() > 0) {
path.reset();
tx.reset();
ty.reset();
for (int i = 0; i < measurementPoints.size(); i++) {
WptPt pt = measurementPoints.get(i);
int locX = tb.getPixXFromLonNoRot(pt.lon);
int locY = tb.getPixYFromLatNoRot(pt.lat);
if (i == 0) {
path.moveTo(locX, locY);
} else {
path.lineTo(locX, locY);
}
tx.add(locX);
ty.add(locY);
if (tb.containsLatLon(pt.lat, pt.lon)) {
canvas.drawBitmap(pointIcon, locX - marginX, locY - marginY, bitmapPaint);
}
}
path.lineTo(tb.getCenterPixelX(), tb.getCenterPixelY());
tx.add(tb.getCenterPixelX());
ty.add(tb.getCenterPixelY());
calculatePath(tb, tx, ty, path);
canvas.drawPath(path, lineAttrs.paint);
}
}
}
private void drawCenterIcon(Canvas canvas, RotatedTileBox tb, QuadPoint center, boolean nightMode) {
canvas.rotate(-tb.getRotate(), center.x, center.y);
if (nightMode) {
canvas.drawBitmap(centerIconNight, center.x - centerIconNight.getWidth() / 2,
center.y - centerIconNight.getHeight() / 2, bitmapPaint);
} else {
canvas.drawBitmap(centerIconDay, center.x - centerIconDay.getWidth() / 2,
center.y - centerIconDay.getHeight() / 2, bitmapPaint);
}
canvas.rotate(tb.getRotate(), center.x, center.y);
}
void addPointOnClick() {
RotatedTileBox tb = view.getCurrentRotatedTileBox();
LatLon l = tb.getLatLonFromPixel(tb.getCenterPixelX(), tb.getCenterPixelY());
WptPt pt = new WptPt();
pt.lat = l.getLatitude();
pt.lon = l.getLongitude();
measurementPoints.add(pt);
view.refreshMap();
}
@Override
public void destroyLayer() {
}
@Override
public boolean drawInScreenPixels() {
return false;
}
}

View file

@ -236,7 +236,11 @@ public class TrackSegmentFragment extends OsmAndListFragment {
}
private GPXFile getGpx() {
return getTrackActivity().getGpx();
TrackActivity activity = getTrackActivity();
if (activity == null) {
return null;
}
return activity.getGpx();
}
private GpxDataItem getGpxDataItem() {

View file

@ -96,7 +96,7 @@ public class UploadOpenstreetmapPointAsyncTask
@Override
protected void onPostExecute(Map<OsmPoint, String> loadErrorsMap) {
if (progress != null) {
progress.dismiss();
progress.dismissAllowingStateLoss();
}
listener.uploadEnded(loadErrorsMap);
}

View file

@ -578,14 +578,19 @@ public class PoiUIFilter implements SearchPoiTypeFilter, Comparable<PoiUIFilter>
private void putAllAcceptedTypes(Map<PoiCategory, LinkedHashSet<String>> types) {
for (PoiCategory category : types.keySet()) {
LinkedHashSet<String> typesSet = types.get(category);
if (acceptedTypes.containsKey(category)) {
if (acceptedTypes.get(category) != null && types.get(category) != null) {
acceptedTypes.get(category).addAll(types.get(category));
if (acceptedTypes.get(category) != null && typesSet != null) {
acceptedTypes.get(category).addAll(typesSet);
} else {
acceptedTypes.put(category, null);
}
} else {
acceptedTypes.put(category, new LinkedHashSet<>(types.get(category)));
if (typesSet != null) {
acceptedTypes.put(category, new LinkedHashSet<>(typesSet));
} else {
acceptedTypes.put(category, null);
}
}
}
}

View file

@ -350,7 +350,7 @@ public class ResourceManager {
public List<String> reloadIndexesOnStart(AppInitializer progress, List<String> warnings){
close();
// check we have some assets to copy to sdcard
warnings.addAll(checkAssets(progress));
warnings.addAll(checkAssets(progress, false));
progress.notifyEvent(InitEvents.ASSETS_COPIED);
reloadIndexes(progress, warnings);
progress.notifyEvent(InitEvents.MAPS_INITIALIZED);
@ -414,9 +414,9 @@ public class ResourceManager {
return warnings;
}
private List<String> checkAssets(IProgress progress) {
public List<String> checkAssets(IProgress progress, boolean forceUpdate) {
String fv = Version.getFullVersion(context);
if (!fv.equalsIgnoreCase(context.getSettings().PREVIOUS_INSTALLED_VERSION.get())) {
if (!fv.equalsIgnoreCase(context.getSettings().PREVIOUS_INSTALLED_VERSION.get()) || forceUpdate) {
File applicationDataDir = context.getAppPath(null);
applicationDataDir.mkdirs();
if (applicationDataDir.canWrite()) {
@ -424,7 +424,7 @@ public class ResourceManager {
progress.startTask(context.getString(R.string.installing_new_resources), -1);
AssetManager assetManager = context.getAssets();
boolean isFirstInstall = context.getSettings().PREVIOUS_INSTALLED_VERSION.get().equals("");
unpackBundledAssets(assetManager, applicationDataDir, progress, isFirstInstall);
unpackBundledAssets(assetManager, applicationDataDir, progress, isFirstInstall || forceUpdate);
context.getSettings().PREVIOUS_INSTALLED_VERSION.set(fv);
copyRegionsBoundaries();
// see Issue #3381

View file

@ -861,7 +861,8 @@ public class ContextMenuLayer extends OsmandMapLayer {
if (movementListener.onTouchEvent(event)) {
if (menu.isVisible()) {
menu.hide();
menu.updateMapCenter(null);
menu.close();
}
if (multiSelectionMenu.isVisible()) {
multiSelectionMenu.hide();

View file

@ -712,7 +712,7 @@ public class MapControlsLayer extends OsmandMapLayer {
((app.accessibilityEnabled() || (System.currentTimeMillis() - touchEvent < TIMEOUT_TO_SHOW_BUTTONS)) && routeFollowingMode);
updateMyLocation(rh, routeDialogOpened || trackDialogOpened);
boolean showButtons = (showRouteCalculationControls || !routeFollowingMode)
&& !isInMovingMarkerMode() && !isInGpxDetailsMode();
&& !isInMovingMarkerMode() && !isInGpxDetailsMode() && !isInMeasurementToolMode();
//routePlanningBtn.setIconResId(routeFollowingMode ? R.drawable.ic_action_gabout_dark : R.drawable.map_directions);
if (rh.isFollowingMode()) {
routePlanningBtn.setIconResId(R.drawable.map_start_navigation);
@ -729,13 +729,14 @@ public class MapControlsLayer extends OsmandMapLayer {
mapZoomIn.updateVisibility(!routeDialogOpened);
mapZoomOut.updateVisibility(!routeDialogOpened);
compassHud.updateVisibility(!routeDialogOpened && !trackDialogOpened && shouldShowCompass());
compassHud.updateVisibility(!routeDialogOpened && !trackDialogOpened && shouldShowCompass() &&
!isInMeasurementToolMode());
if (layersHud.setIconResId(settings.getApplicationMode().getMapIconId())) {
layersHud.update(app, isNight);
}
layersHud.updateVisibility(!routeDialogOpened && !trackDialogOpened);
quickSearchHud.updateVisibility(!routeDialogOpened && !trackDialogOpened);
layersHud.updateVisibility(!routeDialogOpened && !trackDialogOpened && !isInMeasurementToolMode());
quickSearchHud.updateVisibility(!routeDialogOpened && !trackDialogOpened && !isInMeasurementToolMode());
if (!routePlanningMode && !routeFollowingMode) {
if (mapView.isZooming()) {
@ -1127,6 +1128,10 @@ public class MapControlsLayer extends OsmandMapLayer {
return contextMenuLayer.isInGpxDetailsMode();
}
private boolean isInMeasurementToolMode() {
return mapActivity.getMapLayers().getMeasurementToolLayer().isInMeasurementMode();
}
public static View.OnLongClickListener getOnClickMagnifierListener(final OsmandMapTileView view) {
return new View.OnLongClickListener() {

View file

@ -25,6 +25,7 @@ import net.osmand.plus.R;
import net.osmand.plus.activities.MapActivity;
import net.osmand.plus.helpers.AndroidUiHelper;
import net.osmand.plus.mapcontextmenu.MapContextMenu;
import net.osmand.plus.measurementtool.MeasurementToolLayer;
import net.osmand.plus.quickaction.QuickAction;
import net.osmand.plus.quickaction.QuickActionFactory;
import net.osmand.plus.quickaction.QuickActionRegistry;
@ -39,6 +40,7 @@ import static net.osmand.plus.views.ContextMenuLayer.VIBRATE_SHORT;
public class MapQuickActionLayer extends OsmandMapLayer implements QuickActionRegistry.QuickActionUpdatesListener, QuickAction.QuickActionSelectionListener {
private final ContextMenuLayer contextMenuLayer;
private final MeasurementToolLayer measurementToolLayer;
private ImageView contextMarker;
private final MapActivity mapActivity;
private final OsmandApplication app;
@ -63,6 +65,7 @@ public class MapQuickActionLayer extends OsmandMapLayer implements QuickActionRe
app = activity.getMyApplication();
settings = activity.getMyApplication().getSettings();
quickActionRegistry = activity.getMapLayers().getQuickActionRegistry();
measurementToolLayer = mapActivity.getMapLayers().getMeasurementToolLayer();
}
@ -319,6 +322,7 @@ public class MapQuickActionLayer extends OsmandMapLayer implements QuickActionRe
boolean hideQuickButton = !isLayerOn ||
contextMenuLayer.isInChangeMarkerPositionMode() ||
contextMenuLayer.isInGpxDetailsMode() ||
measurementToolLayer.isInMeasurementMode() ||
mapActivity.getContextMenu().isVisible() && !mapActivity.getContextMenu().findMenuFragment().get().isRemoving() ||
mapActivity.getContextMenu().isVisible() && mapActivity.getContextMenu().findMenuFragment().get().isAdded() ||
mapActivity.getContextMenu().getMultiSelectionMenu().isVisible() && mapActivity.getContextMenu().getMultiSelectionMenu().getFragmentByTag().isAdded() ||

View file

@ -5,7 +5,6 @@ import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.Paint;
import android.graphics.Paint.Style;
import android.graphics.Path;
import android.graphics.PointF;
import android.graphics.Rect;
import android.os.Handler;
@ -19,14 +18,13 @@ import net.osmand.data.QuadPoint;
import net.osmand.data.RotatedTileBox;
import net.osmand.plus.OsmAndFormatter;
import net.osmand.plus.OsmandApplication;
import net.osmand.plus.OsmandSettings;
import net.osmand.plus.OsmandSettings.RulerMode;
import net.osmand.plus.R;
import net.osmand.plus.activities.MapActivity;
import java.util.ArrayList;
import gnu.trove.list.array.TIntArrayList;
public class RulerControlLayer extends OsmandMapLayer {
private static final long DRAW_TIME = 2000;
@ -49,14 +47,13 @@ public class RulerControlLayer extends OsmandMapLayer {
private int acceptableTouchRadius;
private QuadPoint cacheCenter;
private float cacheMapDensity;
private OsmandSettings.OsmandPreference<Float> mapDensity;
private int cacheIntZoom;
private double cacheTileX;
private double cacheTileY;
private long cacheMultiTouchEndTime;
private ArrayList<String> cacheDistances;
private Path distancePath;
private TIntArrayList tx;
private TIntArrayList ty;
private LatLon touchPointLatLon;
private PointF touchPoint;
private long touchStartTime;
@ -93,13 +90,12 @@ public class RulerControlLayer extends OsmandMapLayer {
public void initLayer(final OsmandMapTileView view) {
app = mapActivity.getMyApplication();
this.view = view;
mapDensity = mapActivity.getMyApplication().getSettings().MAP_DENSITY;
cacheMapDensity = mapDensity.get();
cacheDistances = new ArrayList<>();
cacheCenter = new QuadPoint();
maxRadiusInDp = mapActivity.getResources().getDimensionPixelSize(R.dimen.map_ruler_width);
rightWidgetsPanel = mapActivity.findViewById(R.id.map_right_widgets_panel);
distancePath = new Path();
tx = new TIntArrayList();
ty = new TIntArrayList();
touchPoint = new PointF();
acceptableTouchRadius = mapActivity.getResources().getDimensionPixelSize(R.dimen.acceptable_touch_radius);
@ -307,12 +303,13 @@ public class RulerControlLayer extends OsmandMapLayer {
}
boolean move = tb.getZoom() != cacheIntZoom || Math.abs(tb.getCenterTileX() - cacheTileX) > 1 ||
Math.abs(tb.getCenterTileY() - cacheTileY) > 1;
Math.abs(tb.getCenterTileY() - cacheTileY) > 1 || mapDensity.get() != cacheMapDensity;
if (!tb.isZoomAnimated() && move) {
cacheIntZoom = tb.getZoom();
cacheTileX = tb.getCenterTileX();
cacheTileY = tb.getCenterTileY();
cacheMapDensity = mapDensity.get();
cacheDistances.clear();
updateDistance(tb);
}

View file

@ -1048,6 +1048,8 @@ public class RouteInfoWidgetsFactory {
private MapActivity ma;
private String cacheRulerText;
private int maxWidth;
private float cacheMapDensity;
private OsmandSettings.OsmandPreference<Float> mapDensity;
private int cacheRulerZoom;
private double cacheRulerTileX;
private double cacheRulerTileY;
@ -1061,6 +1063,8 @@ public class RouteInfoWidgetsFactory {
textShadow = (TextView) ma.findViewById(R.id.map_ruler_text_shadow);
maxWidth = ma.getResources().getDimensionPixelSize(R.dimen.map_ruler_width);
orientationPortrait = AndroidUiHelper.isOrientationPortrait(ma);
mapDensity = ma.getMyApplication().getSettings().MAP_DENSITY;
cacheMapDensity = mapDensity.get();
}
public void updateTextSize(boolean isNight, int textColor, int textShadowColor, int shadowRadius) {
@ -1077,10 +1081,12 @@ public class RouteInfoWidgetsFactory {
} else if (!orientationPortrait && ma.getRoutingHelper().isRoutePlanningMode()) {
visible = false;
} else if (!tb.isZoomAnimated() && (tb.getZoom() != cacheRulerZoom || Math.abs(tb.getCenterTileX() - cacheRulerTileX) > 1 || Math
.abs(tb.getCenterTileY() - cacheRulerTileY) > 1) && tb.getPixWidth() > 0 && maxWidth > 0) {
.abs(tb.getCenterTileY() - cacheRulerTileY) > 1 || mapDensity.get() != cacheMapDensity) &&
tb.getPixWidth() > 0 && maxWidth > 0) {
cacheRulerZoom = tb.getZoom();
cacheRulerTileX = tb.getCenterTileX();
cacheRulerTileY = tb.getCenterTileY();
cacheMapDensity = mapDensity.get();
final double dist = tb.getDistance(0, tb.getPixHeight() / 2, tb.getPixWidth(), tb.getPixHeight() / 2);
double pixDensity = tb.getPixWidth() / dist;
double roundedDist = OsmAndFormatter.calculateRoundedDist(maxWidth /

View file

@ -110,8 +110,8 @@ repositories {
dependencies {
compile project(path: ':OsmAnd-java', configuration: 'android')
compile 'com.android.support:appcompat-v7:23.3.0'
compile 'com.android.support:design:23.3.0'
compile 'com.android.support:appcompat-v7:25.+'
compile 'com.android.support:design:25.+'
compile fileTree(dir: "libs", include: ["*.jar"])
compile "net.osmand:OsmAndCore_android:0.1-SNAPSHOT@aar"
debugCompile "net.osmand:OsmAndCore_androidNativeRelease:0.1-SNAPSHOT@aar"

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

View file

@ -39,7 +39,7 @@ public class InstallOsmandAppDialog extends AppCompatDialogFragment {
view.findViewById(R.id.install_osmand_btn).setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
boolean success = execOsmAndInstall("market://search?q=pname:");
boolean success = execOsmAndInstall("market://details?id=");
if (!success) {
success = execOsmAndInstall("https://play.google.com/store/apps/details?id=");
}

View file

@ -62,7 +62,7 @@ public class ContextMenuHelper {
final Toolbar topBar = new Toolbar(ctx);
topBar.setClickable(true);
Drawable back = app.getIconsCache().getIcon(R.drawable.abc_ic_ab_back_mtrl_am_alpha);
Drawable back = app.getIconsCache().getIcon(R.drawable.ic_arrow_back);
topBar.setNavigationIcon(back);
topBar.setNavigationContentDescription(app.getString("access_shared_string_navigate_up"));
topBar.setTitle(title);
@ -220,7 +220,7 @@ public class ContextMenuHelper {
final Toolbar topBar = new Toolbar(ctx);
topBar.setClickable(true);
Drawable back = app.getIconsCache().getIcon(R.drawable.abc_ic_ab_back_mtrl_am_alpha);
Drawable back = app.getIconsCache().getIcon(R.drawable.ic_arrow_back);
topBar.setNavigationIcon(back);
topBar.setNavigationContentDescription(app.getString("access_shared_string_navigate_up"));
topBar.setTitle(title);

View file

@ -203,7 +203,7 @@ public class QuickSearchDialogFragment extends DialogFragment implements SampleC
);
toolbar = (Toolbar) view.findViewById(R.id.toolbar);
toolbar.setNavigationIcon(app.getIconsCache().getThemedIcon(R.drawable.abc_ic_ab_back_mtrl_am_alpha));
toolbar.setNavigationIcon(app.getIconsCache().getThemedIcon(R.drawable.ic_arrow_back));
toolbar.setNavigationContentDescription(app.getString("access_shared_string_navigate_up"));
toolbar.setNavigationOnClickListener(
new OnClickListener() {

View file

@ -57,7 +57,7 @@ public class NauticalActivity extends Activity {
public void onClick(View v) {
String appName = OSMAND_COMPONENT;
logEvent(NauticalActivity.this, "open_play_store_" + appName);
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://search?q=pname:" + appName));
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + appName));
try {
//stopService(intent);
startActivity(intent);

View file

@ -56,7 +56,7 @@ public class ParkingPluginActivity extends Activity {
public void onClick(View v) {
String appName = OSMAND_COMPONENT;
logEvent(ParkingPluginActivity.this, "open_play_store_" + appName);
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://search?q=pname:" + appName));
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + appName));
try {
//stopService(intent);
startActivity(intent);

View file

@ -58,7 +58,7 @@ public class SRTMPluginActivity extends Activity {
public void onClick(View v) {
String appName = OSMAND_COMPONENT;
logEvent(SRTMPluginActivity.this, "open_play_store_" + appName);
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://search?q=pname:" + appName));
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + appName));
try {
//stopService(intent);
startActivity(intent);

View file

@ -59,7 +59,7 @@ public class SkiMapsActivity extends Activity {
public void onClick(View v) {
String appName = OSMAND_COMPONENT;
logEvent(SkiMapsActivity.this, "open_play_store_" + appName);
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://search?q=pname:" + appName));
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + appName));
try {
//stopService(intent);
startActivity(intent);