From de6e16b5837df8e0dce33f31374170e433907ed2 Mon Sep 17 00:00:00 2001 From: Alexey Kulish Date: Tue, 12 Jan 2016 10:19:05 +0300 Subject: [PATCH 01/32] Fix - display group name Favorites at Waypoints --- OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java b/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java index b604345791..fce524441e 100644 --- a/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java +++ b/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java @@ -114,7 +114,7 @@ public class WaypointDialogHelper { case WaypointHelper.FAVORITES: FavouritePoint favPoint = (FavouritePoint) ps.point; - pointDescription = favPoint.getCategory(); + pointDescription = Algorithms.isEmpty(favPoint.getCategory()) ? activity.getResources().getString(R.string.shared_string_favorites) : favPoint.getCategory(); break; } } From 8753592e3ea0f68637953cada51c7e5ff7351c29 Mon Sep 17 00:00:00 2001 From: xmd5a Date: Tue, 12 Jan 2016 14:50:27 +0300 Subject: [PATCH 02/32] update phrases --- OsmAnd/res/values-ru/phrases.xml | 15 +++++++++++++++ OsmAnd/res/values/phrases.xml | 18 +++++++++++++++++- 2 files changed, 32 insertions(+), 1 deletion(-) diff --git a/OsmAnd/res/values-ru/phrases.xml b/OsmAnd/res/values-ru/phrases.xml index 7f09dd3753..47d97d21b9 100644 --- a/OsmAnd/res/values-ru/phrases.xml +++ b/OsmAnd/res/values-ru/phrases.xml @@ -2571,4 +2571,19 @@ Официальное имя + Насыпь для сдерживания потока воды + + Указатель: квартальный столб + Указатель: деляночный столб + Надпись:С + Надпись:СВ + Надпись:В + Надпись:ЮВ + Надпись:Ю + Надпись:ЮЗ + Надпись:З + Надпись:СЗ + + В процессе строительства + diff --git a/OsmAnd/res/values/phrases.xml b/OsmAnd/res/values/phrases.xml index 749710c6fe..0743605e38 100644 --- a/OsmAnd/res/values/phrases.xml +++ b/OsmAnd/res/values/phrases.xml @@ -953,7 +953,7 @@ Daymark Distance mark Dry dock - Dyke + Seamark dyke Floating dock Fog signal Harbour basin @@ -2566,4 +2566,20 @@ Official name + Dyke + Dolphin + + Signpost: forestry compartment + Signpost: forestry allotment + Inscription:N + Inscription:NW + Inscription:W + Inscription:SW + Inscription:S + Inscription:SE + Inscription:E + Inscription:NE + + Under construction + From 510969942b54fbc75050be54cc8709fc6a3d8524 Mon Sep 17 00:00:00 2001 From: jan madsen Date: Tue, 12 Jan 2016 13:02:54 +0100 Subject: [PATCH 03/32] Translated using Weblate (Danish) Currently translated at 100.0% (2376 of 2376 strings) --- OsmAnd/res/values-da/phrases.xml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/OsmAnd/res/values-da/phrases.xml b/OsmAnd/res/values-da/phrases.xml index 3c50d8b42d..007ea2486e 100644 --- a/OsmAnd/res/values-da/phrases.xml +++ b/OsmAnd/res/values-da/phrases.xml @@ -2623,4 +2623,20 @@ Officielle navn +Sømærke dige + Delfin + + Vejskilt: skovbrugshytte + Vejskilt: skovbrug tildeling + Inskription: N + Inskription: NV + Inskription: V + Inskription: SV + Inskription: S + Inskription: SØ + Inskription: Ø + Inskription: NØ + + Under opførelse + From 0edcdcaa1b7b651577a0c84ba0c5b5b77c0c85d9 Mon Sep 17 00:00:00 2001 From: Dmitriy Prodchenko Date: Tue, 12 Jan 2016 14:57:31 +0200 Subject: [PATCH 04/32] Reorder icon for Waypoints screen. --- OsmAnd/res/drawable-hdpi/ic_action_reorder.png | Bin 0 -> 1080 bytes OsmAnd/res/drawable-mdpi/ic_action_reorder.png | Bin 0 -> 1059 bytes OsmAnd/res/drawable-xhdpi/ic_action_reorder.png | Bin 0 -> 1099 bytes OsmAnd/res/drawable-xxhdpi/ic_action_reorder.png | Bin 0 -> 1148 bytes 4 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 OsmAnd/res/drawable-hdpi/ic_action_reorder.png create mode 100644 OsmAnd/res/drawable-mdpi/ic_action_reorder.png create mode 100644 OsmAnd/res/drawable-xhdpi/ic_action_reorder.png create mode 100644 OsmAnd/res/drawable-xxhdpi/ic_action_reorder.png diff --git a/OsmAnd/res/drawable-hdpi/ic_action_reorder.png b/OsmAnd/res/drawable-hdpi/ic_action_reorder.png new file mode 100644 index 0000000000000000000000000000000000000000..1180451a26aec085cd2c21b17d047bc46e77ddbb GIT binary patch literal 1080 zcmaJ=y>HV%6gLI&QMDsNbir~NsNiCsV>`ChP|~EKDI}CMv?&v3`_fpcea5~Lw+ui9 zNc;hn%D}?Vk&TG~F@QuT1{P2m7+4Te2lk3{K1zqGmd^L??)~2Ty{{LumFvTUBZC~r z4VR`1RkmMD*6EY%|C8I?WZQWelMC zUcPDC#7m(>Clz}ELv!5tL>wTyg(+|0CD+diyYJo$yz69z1+^@dgFJ4!(`zA~TdUOU zwU%u-!o*d6JT{pD4^za)-m)K=aaQQqHJO}Tivr(Kp{=aYB~>ra@_7Nw$Oi^sN+o^UsMZzT! z8ipZCvM9@dX@F?erzi$~G}^aNz>yug0dDfrcSgZA-xo%jw%W46kd&oFrx7q#@@Z zoKkbSqLNed`3w_vBa`oAOMXO=Z{xmim-+5tr6aLsKE#NUutvyozYAuYgp#O90zRMb zRGq)H;Q9_}M`KBux=|N!=sv(sF(e+}$+PJm#-X8N1PvWnN<#%1MS(y!pa!6>$+~14 z7RFfU;hh8d>-H(TVQ~a~I;LhL%~sM9K)NLX$WjQbhOGj-q39^B>uCidL1Yxgq;(Fo zQvZteXCm$o20QGJ7WUaZg=}yxFaCJThHj=*$kpQSf4+V=!|_8Ozs&DE`ei=JY^?8I z$Ub|%dFSja?e#bA*Z_SP{oVT=&1_f3Zk(&W+^!Yb+LAYJZ^_pl@13|iFvL|_rxrhr R?93;#T$-vB-b~(G{|7FI-71X}8mTEIjns&#XZze(t$oJ6Hf~2? zVd!swk%>RRfEZbj*boyEKY*11shpFzbf~c8`*`nt-uHRGUTi5d>kbz3z7T zK41Pfuk-cC(D}``JFMAf+cacDoDrcOP>+c181IoT!NKwK&tzE;re8(9KI?ZjY@fz5 zE_LK0PB~f-mRE}u`}>569@&c$NBZ^Qqa;RwBkdR+wUai;AX-1k$o9!*&p+AsQ6R0Z zh|7h|4a9_Dv4{_n+%6nxWY^~BQmjbgNQLb?(wJ1gvn4iYMnpq4fe#@Rmyiq%tEL%` zL`{W;q9O&VK!r9`ZA}#?pTxaoL1=f~*2EXTInsc!)K-+?a3~LJGR^iBh!9d#P0=*K zH9&rxFkFBnU#u*+B=@r@Wf4up(jxZgA#)_obR0sQb~@*VlYEjWo-(DtsRCtHiQ_V^ zk#^3y0##cdW4G=nCI^Qj!H$&#(t7TyeRmApAXP^Ip+EyBfyD4VorGRc*|`jFHFXWSYHbZ^bqJfr8eB45)G}Kx zG?A|96}Fw^3@1LRd`H~(1grfQYd1228O?f>9#mbhHK2^<1DcAB#;EGz{hcTY=rDg! zmT4TdOS0&Q1g(t5;waB{bQy=xAQ&PGczS4nC0&QWLeK=zGBr!}kw*xTCivh&{>FXE zB|MI_qGOvrHhsOO0&ICIfINl33w;Clp>E-tWz}?uC52N|%GSBiN|lKBXL&py41PHu zEt2qg%J|^id;4&Q51r9=>%HQ;_vh?vbs9|Fo<9Bb?%LI<*@ZXH;1_FmW%uss%dgh_ gWO+I}m=dns62ASsQI9uHkIJ!aH#gn)Yr8N00{7fU%>V!Z literal 0 HcmV?d00001 diff --git a/OsmAnd/res/drawable-xhdpi/ic_action_reorder.png b/OsmAnd/res/drawable-xhdpi/ic_action_reorder.png new file mode 100644 index 0000000000000000000000000000000000000000..09931760cff5463c83328da0bbf543186014c391 GIT binary patch literal 1099 zcmaJ=O=#3W6rNhCBD4r9qP>I^L7}sm$tKw(bgjFa)h@cVtgGFN;3S!CLz_&ROx?7n zA_eiLcSTQn5EQ|ihkErY2;#|$;6e1@MQ={FyVXN6A(@#s-}nCCy@mNp<3~;(0RW6Q z=A4#TQT`ns6aU2nzwe6W6t8#qHP+=ll2B0bnMv0wu*Gn>W4TcKQX=~57tl!dENYG-A+uh$m)T&&1aAHrA4@~%^z=7LmX36=DM0X>YdRI&|BMWPZ-?dxL#epqxD$C29$F`#Mdc8ugSYXMLf-TEZ zkgBLE6bP7ZM4V(WN~eYz9GZGb5c7aVQm&D>Y@L^7;puJ&Vccx)DUQ-XqD0D+jKm5q zASDd*xccanx9DFt_C=@djhHGenzHr86ZPm$4ap*R|2LEag*W!qBoIX*s}A$lLmKgh zQ{#%RZFd4T-Pg_ zc#V2RGfO(wus-BAqLh=!qeI()usz^b{>!y%2_>8*ZN^rIU9hmsI7^pVEY)iLs!L}V zgUDyS^ju!1-KZU!1h=VwF=3(9&$Auu=R;Sg1Y0I_wXP0JnueiiVFO~*P)+1nE~Qi+ z@cn=Cx7(*eBI1aL?%0M$3{NW}NK6+&EK&&FuBSt#l!(E33Mz^ix|b`0O=#3W6i%yX6$_$J)YBL*3Qm&ACfOu(ZMU0h7u;Ibl`d4!Niy4pHkp`A-EA)| z>O~LY#hZeH2M;3nb5jrxVg)^Ush;(wc+rCh;$*v9dngSgGxO&A-v7(>iSbkYyASOa z1fjn?=2ZDQmc4yD`1joRXQ%jbkd4;aS=wMtoDiYtQi%5^S%`1-;lZ7jQA8F=>Q z&H>QFHy_)SeN(5ea>4NO9O_Tp-oCwH>it0KE(^N=zuBNNL;w0Pa8Y>qcjx`PpL%a( O|AX@Axbt}A;+21ea%FJ< literal 0 HcmV?d00001 From 3c4596e6c6789b919d12ae86a80f21562d2e2db1 Mon Sep 17 00:00:00 2001 From: Ersan Doru Date: Tue, 12 Jan 2016 13:02:19 +0100 Subject: [PATCH 05/32] Translated using Weblate (Turkish) Currently translated at 100.0% (1877 of 1877 strings) --- OsmAnd/res/values-tr/strings.xml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/OsmAnd/res/values-tr/strings.xml b/OsmAnd/res/values-tr/strings.xml index 1ff10e4d63..7848556f48 100644 --- a/OsmAnd/res/values-tr/strings.xml +++ b/OsmAnd/res/values-tr/strings.xml @@ -1,4 +1,5 @@ -Değişiklik listesini kapat + +Değişiklik listesini kapat ZXing Barcode Scanner uygulaması kurulu değil. Uygulama marketinde aramak ister misiniz? Yol renk şemasını seç: Yol renk şeması @@ -1327,7 +1328,7 @@ Mekik treninden kaçın Vikipedi - OSM Düzeltmesini Sil + OSM düzeltmesini sil Rota kapsamına göre Boyama Çıkış yap OsmAnd\'ın verileri ayrıca yeni hedefe de kopyalamasını ister misiniz? @@ -2030,4 +2031,4 @@ UNDO TÜM Tip Başlangıç noktası - \ No newline at end of file + From 6eb02630a0a93d0ceaa51e87c4015c019ca9cf2e Mon Sep 17 00:00:00 2001 From: xmd5a Date: Tue, 12 Jan 2016 15:03:52 +0300 Subject: [PATCH 06/32] Update phrases --- OsmAnd/res/values-ru/phrases.xml | 2 ++ OsmAnd/res/values/phrases.xml | 2 ++ 2 files changed, 4 insertions(+) diff --git a/OsmAnd/res/values-ru/phrases.xml b/OsmAnd/res/values-ru/phrases.xml index 47d97d21b9..138d4e7342 100644 --- a/OsmAnd/res/values-ru/phrases.xml +++ b/OsmAnd/res/values-ru/phrases.xml @@ -2585,5 +2585,7 @@ Надпись:СЗ В процессе строительства + С банкоматом + Без банкомата diff --git a/OsmAnd/res/values/phrases.xml b/OsmAnd/res/values/phrases.xml index 0743605e38..c4f0f04f46 100644 --- a/OsmAnd/res/values/phrases.xml +++ b/OsmAnd/res/values/phrases.xml @@ -2581,5 +2581,7 @@ Inscription:NE Under construction + Atm: yes + Atm: no From 89f5d583fff0b3092f6f5cd648ae54a4da5ab88c Mon Sep 17 00:00:00 2001 From: xmd5a Date: Tue, 12 Jan 2016 17:45:42 +0300 Subject: [PATCH 07/32] Update strings --- OsmAnd/res/values-ru/strings.xml | 1 + OsmAnd/res/values/strings.xml | 1 + 2 files changed, 2 insertions(+) diff --git a/OsmAnd/res/values-ru/strings.xml b/OsmAnd/res/values-ru/strings.xml index aff765b46e..bf479cb885 100644 --- a/OsmAnd/res/values-ru/strings.xml +++ b/OsmAnd/res/values-ru/strings.xml @@ -1,5 +1,6 @@ + Скрыть значки Конные маршруты Низкое качество Высокое качество diff --git a/OsmAnd/res/values/strings.xml b/OsmAnd/res/values/strings.xml index 91f80b908c..9c3b3a88c6 100644 --- a/OsmAnd/res/values/strings.xml +++ b/OsmAnd/res/values/strings.xml @@ -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 --> + Hide icons Item deleted items deleted UNDO ALL From 448f67aa4f2deb06c82b1d3ec56a5a9f7ab3efd2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A1=D0=B0=D1=88=D0=B0=20=D0=9F=D0=B5=D1=82=D1=80=D0=BE?= =?UTF-8?q?=D0=B2=D0=B8=D1=9B?= Date: Tue, 12 Jan 2016 15:39:57 +0100 Subject: [PATCH 08/32] Translated using Weblate (Serbian) Currently translated at 50.7% (953 of 1877 strings) --- OsmAnd/res/values-sr/strings.xml | 46 ++++++++++++++++++++++++++++++-- 1 file changed, 44 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-sr/strings.xml b/OsmAnd/res/values-sr/strings.xml index 7160a32014..9ab1b3d82f 100644 --- a/OsmAnd/res/values-sr/strings.xml +++ b/OsmAnd/res/values-sr/strings.xml @@ -1,4 +1,5 @@ - + + Верзија: Oko Верзија инфо, лиценце, чланови пројекта @@ -977,4 +978,45 @@ " • Ново сучеље осетљиво на положај тапкања по карти или другим површима\n\n • Приказ карте се сада покреће непосредно осим ако је означено „Приказуј полетника при покретању“\n\n • Подешава се која карта и како се приказује у полетнику\n\n • Премошћава се полетник ако Вам се више свиђа управљање програмом изборником\n\n • За преузимање карата, области се могу непосредно изабрати тапкањем по светској карти\n\n • Претрага тачака занимања сада подржава одређеније упите\n\n • Побољшане су могућности тачака занимања и уређивања ОСМ-а\n\n • Прерађен је склоп преузимања карата и његово сучеље\n\n и још којешта... " Слој сенчења падина је онемогућен - \ No newline at end of file + Албански + Арапски + Баскијски + Белоруски + Бугарски + Хрватски + Чешки + Дански + Фински + Француски + Германски + Грчки + Мађарски + Индонезијски + Италијански + Јапански + Корејски + Норвешки + Персијски + Пољски + Португалски + Румунски + Руски + Словачки + Шпански + Шведски + Турски + Украјински + Вијетнамски + Северна Америка - Канада + Европа - Италија + Европа - Велика Британија + Рачунај одсечак стазе Османда без приступа мрежи + Рачунај од првог до последњег осдечка стазе Османда + Да ли желите приказ стазе за навођење? + Изаберите ГПИкс… + Избегавај путеве са наплатним станицама + Избегавај путеве са наплатним станицама + Избегавај неасвалтиране путеве + Избегавај неасвалтиране путеве + Одреди/уреди… + From 568dc6f1bf8c4845880d7a33b24f548417de8993 Mon Sep 17 00:00:00 2001 From: xmd5a Date: Tue, 12 Jan 2016 17:49:20 +0300 Subject: [PATCH 09/32] Fix phrases --- OsmAnd/res/values-ru/phrases.xml | 1 - 1 file changed, 1 deletion(-) diff --git a/OsmAnd/res/values-ru/phrases.xml b/OsmAnd/res/values-ru/phrases.xml index 138d4e7342..6b440c770e 100644 --- a/OsmAnd/res/values-ru/phrases.xml +++ b/OsmAnd/res/values-ru/phrases.xml @@ -875,7 +875,6 @@ Художественная галерея Горнолыжный курорт Площадка для игр - Насыпь Платежный терминал Часы работы From 717adce97a77fb7c750fc3c98626524fee897b65 Mon Sep 17 00:00:00 2001 From: Alexey Kulish Date: Tue, 12 Jan 2016 17:55:14 +0300 Subject: [PATCH 10/32] Fix - add popup menu 'Delete' at Waypoints. Fix - crash on flat waypoints list --- OsmAnd/res/layout/waypoint_reached.xml | 1 - OsmAnd/res/values/strings.xml | 1 + .../plus/activities/MapActivityActions.java | 8 +- .../plus/dashboard/DashWaypointsFragment.java | 2 +- .../osmand/plus/dashboard/DashboardOnMap.java | 39 ++--- .../plus/helpers/WaypointDialogHelper.java | 135 ++++++++++++++---- .../MapContextMenuFragment.java | 37 +---- .../plus/views/controls/DynamicListView.java | 42 ++++-- .../plus/views/controls/SingleTapConfirm.java | 37 +++++ .../SwipeDismissListViewTouchListener.java | 14 +- 10 files changed, 211 insertions(+), 105 deletions(-) create mode 100644 OsmAnd/src/net/osmand/plus/views/controls/SingleTapConfirm.java diff --git a/OsmAnd/res/layout/waypoint_reached.xml b/OsmAnd/res/layout/waypoint_reached.xml index 50a4772d9e..cb7b9df929 100644 --- a/OsmAnd/res/layout/waypoint_reached.xml +++ b/OsmAnd/res/layout/waypoint_reached.xml @@ -99,7 +99,6 @@ android:clickable="false" android:scaleType="center" android:src="@drawable/ic_flat_list_dark" - android:tag="DragIcon" android:visibility="gone"/> \ No newline at end of file diff --git a/OsmAnd/res/values/strings.xml b/OsmAnd/res/values/strings.xml index 91f80b908c..b2b735f893 100644 --- a/OsmAnd/res/values/strings.xml +++ b/OsmAnd/res/values/strings.xml @@ -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 --> + Switch start & finish Item deleted items deleted UNDO ALL diff --git a/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java b/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java index fb7dd9f67f..9c19de02c2 100644 --- a/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java +++ b/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java @@ -86,7 +86,7 @@ public class MapActivityActions implements DialogProvider { routingHelper = mapActivity.getMyApplication().getRoutingHelper(); } - + /* public void addAsWaypoint(double latitude, double longitude, PointDescription pd) { TargetPointsHelper targets = getMyApplication().getTargetPointsHelper(); boolean destination = (targets.getPointToNavigate() == null); @@ -97,7 +97,8 @@ public class MapActivityActions implements DialogProvider { openIntermediateEditPointsDialog(); } - + */ + public void addAsTarget(double latitude, double longitude, PointDescription pd) { TargetPointsHelper targets = getMyApplication().getTargetPointsHelper(); targets.navigateToPoint(new LatLon(latitude, longitude), true, targets.getIntermediatePoints().size() + 1, @@ -736,9 +737,11 @@ public class MapActivityActions implements DialogProvider { mapActivity.getDashboard().setDashboardVisibility(true, DashboardType.WAYPOINTS); } + /* public void openIntermediateEditPointsDialog() { mapActivity.getDashboard().setDashboardVisibility(true, DashboardType.WAYPOINTS_EDIT); } + */ public void openRoutePreferencesDialog() { mapActivity.getDashboard().setDashboardVisibility(true, DashboardType.ROUTE_PREFERENCES); @@ -758,6 +761,7 @@ public class MapActivityActions implements DialogProvider { settings.LAST_ROUTING_APPLICATION_MODE = settings.APPLICATION_MODE.get(); settings.APPLICATION_MODE.set(settings.DEFAULT_APPLICATION_MODE.get()); mapActivity.updateApplicationModeSettings(); + mapActivity.getDashboard().clearDeletedPoints(); } public AlertDialog stopNavigationActionConfirm() { diff --git a/OsmAnd/src/net/osmand/plus/dashboard/DashWaypointsFragment.java b/OsmAnd/src/net/osmand/plus/dashboard/DashWaypointsFragment.java index 0d5a723f89..edace008cf 100644 --- a/OsmAnd/src/net/osmand/plus/dashboard/DashWaypointsFragment.java +++ b/OsmAnd/src/net/osmand/plus/dashboard/DashWaypointsFragment.java @@ -96,7 +96,7 @@ public class DashWaypointsFragment extends DashLocationFragment { View dv = getActivity().getLayoutInflater().inflate(R.layout.divider, null); favorites.addView(dv); View v = WaypointDialogHelper.updateWaypointItemView(false, null, getMyApplication(), - getActivity(), null, ps, null, !getMyApplication().getSettings().isLightContent(), true); + getActivity(), null, null, ps, null, !getMyApplication().getSettings().isLightContent(), true); favorites.addView(v); } diff --git a/OsmAnd/src/net/osmand/plus/dashboard/DashboardOnMap.java b/OsmAnd/src/net/osmand/plus/dashboard/DashboardOnMap.java index 364efa4192..c1f3373e18 100644 --- a/OsmAnd/src/net/osmand/plus/dashboard/DashboardOnMap.java +++ b/OsmAnd/src/net/osmand/plus/dashboard/DashboardOnMap.java @@ -54,6 +54,7 @@ import net.osmand.plus.dialogs.ConfigureMapMenu; import net.osmand.plus.download.DownloadActivity; import net.osmand.plus.helpers.AndroidUiHelper; import net.osmand.plus.helpers.WaypointDialogHelper; +import net.osmand.plus.helpers.WaypointDialogHelper.PointDeleteCallback; import net.osmand.plus.helpers.WaypointHelper.LocationPointWrapper; import net.osmand.plus.mapcontextmenu.other.RoutePreferencesMenu; import net.osmand.plus.mapcontextmenu.other.RoutePreferencesMenu.LocalRoutingParameter; @@ -79,7 +80,8 @@ import static android.util.TypedValue.COMPLEX_UNIT_DIP; /** */ -public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicListViewCallbacks, IRouteInformationListener { +public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicListViewCallbacks, + IRouteInformationListener, PointDeleteCallback { private static final org.apache.commons.logging.Log LOG = PlatformUtil.getLog(DashboardOnMap.class); private static final String TAG = "DashboardOnMap"; @@ -149,7 +151,6 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis public enum DashboardType { WAYPOINTS, WAYPOINTS_FLAT, - WAYPOINTS_EDIT, CONFIGURE_SCREEN, CONFIGURE_MAP, LIST_MENU, @@ -178,6 +179,7 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis public void createDashboardView() { baseColor = mapActivity.getResources().getColor(R.color.osmand_orange) & 0x00ffffff; waypointDialogHelper = new WaypointDialogHelper(mapActivity); + waypointDialogHelper.setPointDeleteCallback(this); landscape = !AndroidUiHelper.isOrientationPortrait(mapActivity); dashboardView = (FrameLayout) mapActivity.findViewById(R.id.dashboard); final View.OnClickListener listener = new View.OnClickListener() { @@ -202,7 +204,7 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis @Override public boolean canDismiss(int position) { boolean res = false; - if (listAdapter instanceof StableArrayAdapter) { + if (visibleType == DashboardType.WAYPOINTS && listAdapter instanceof StableArrayAdapter) { List activeObjects = ((StableArrayAdapter) listAdapter).getActiveObjects(); Object obj = listAdapter.getItem(position); res = activeObjects.contains(obj); @@ -232,7 +234,6 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis stableAdapter = null; activeObjPos = 0; } - return new Undoable() { @Override public void undo() { @@ -242,7 +243,6 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis stableAdapter.getObjects().add(position, item); stableAdapter.getActiveObjects().add(activeObjPos, item); stableAdapter.refreshData(); - onItemsSwapped(stableAdapter.getActiveObjects()); } } @@ -380,7 +380,7 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis // // @Override // public void onClick(View v) { - mapActivity.getMyApplication().getWaypointHelper().removeVisibleLocationPoint(deletedPoints); +// mapActivity.getMyApplication().getWaypointHelper().removeVisibleLocationPoint(deletedPoints); // hideDashboard(); // } // }); @@ -473,7 +473,7 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis button = actionButtons.get(DashboardActionButtonType.MY_LOCATION); } else if (type == DashboardType.ROUTE_PREFERENCES) { button = actionButtons.get(DashboardActionButtonType.NAVIGATE); - } else if (type == DashboardType.WAYPOINTS || type == DashboardType.WAYPOINTS_EDIT || type == DashboardType.WAYPOINTS_FLAT) { + } else if (type == DashboardType.WAYPOINTS || type == DashboardType.WAYPOINTS_FLAT) { boolean routePlanningMode = false; RoutingHelper rh = mapActivity.getRoutingHelper(); if (rh.isRoutePlanningMode()) { @@ -679,13 +679,6 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis dynamicListView.setActiveItemsList(listAdapter.getActiveObjects()); updateListAdapter(listAdapter, listener); - } else if (DashboardType.WAYPOINTS_EDIT == visibleType) { - deletedPoints.clear(); - ArrayAdapter listAdapter = waypointDialogHelper.getWaypointsDrawerAdapter(true, deletedPoints, mapActivity, running, - DashboardType.WAYPOINTS_FLAT == visibleType, nightMode); - OnItemClickListener listener = waypointDialogHelper.getDrawerItemClickListener(mapActivity, running, - listAdapter); - updateListAdapter(listAdapter, listener); } else { if (DashboardType.CONFIGURE_SCREEN == visibleType) { @@ -718,8 +711,7 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis } public void refreshContent(boolean force) { - if (visibleType == DashboardType.WAYPOINTS || visibleType == DashboardType.WAYPOINTS_EDIT - || force) { + if (visibleType == DashboardType.WAYPOINTS || force) { updateListAdapter(); } else if (visibleType == DashboardType.CONFIGURE_MAP || visibleType == DashboardType.ROUTE_PREFERENCES) { int index = listView.getFirstVisiblePosition(); @@ -981,7 +973,6 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis private boolean isActionButtonVisible() { return visibleType == DashboardType.DASHBOARD || visibleType == DashboardType.WAYPOINTS - || visibleType == DashboardType.WAYPOINTS_EDIT || visibleType == DashboardType.WAYPOINTS_FLAT || visibleType == DashboardType.LIST_MENU || visibleType == DashboardType.ROUTE_PREFERENCES @@ -1132,6 +1123,10 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis transaction.show(frag).commit(); } + public void clearDeletedPoints() { + deletedPoints.clear(); + } + View getParentView() { return dashboardView; } @@ -1167,7 +1162,7 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis getMyApplication().runInUIThread(new Runnable() { @Override public void run() { - if (visibleType == DashboardType.WAYPOINTS) { + if (visibleType == DashboardType.WAYPOINTS || visibleType == DashboardType.WAYPOINTS_FLAT) { List allTargets = new ArrayList<>(); if (items != null) { for (Object obj : items) { @@ -1203,6 +1198,7 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis if ((DashboardType.WAYPOINTS == visibleType || DashboardType.WAYPOINTS_FLAT == visibleType) && listAdapter != null && listAdapter instanceof StableArrayAdapter) { StableArrayAdapter stableAdapter = (StableArrayAdapter) listAdapter; + getMyApplication().getWaypointHelper().removeVisibleLocationPoint(deletedPoints); waypointDialogHelper.reloadListAdapter(stableAdapter); if (listView instanceof DynamicListView) { DynamicListView dynamicListView = (DynamicListView) listView; @@ -1223,4 +1219,11 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis swipeDismissListener.discardUndo(); } } + + @Override + public void deleteWaypoint(int position) { + if (swipeDismissListener != null) { + swipeDismissListener.delete(position); + } + } } diff --git a/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java b/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java index fce524441e..f526b0ed6b 100644 --- a/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java +++ b/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java @@ -5,13 +5,14 @@ import android.content.Context; import android.content.DialogInterface; import android.content.DialogInterface.OnClickListener; import android.content.DialogInterface.OnDismissListener; -import android.graphics.drawable.BitmapDrawable; import android.graphics.drawable.Drawable; import android.graphics.drawable.ShapeDrawable; import android.graphics.drawable.shapes.Shape; import android.os.AsyncTask; import android.support.v4.app.FragmentActivity; import android.support.v7.app.AlertDialog; +import android.support.v7.widget.PopupMenu; +import android.view.MenuItem; import android.view.View; import android.view.ViewGroup; import android.widget.AdapterView; @@ -31,10 +32,11 @@ import net.osmand.plus.OsmAndFormatter; import net.osmand.plus.OsmandApplication; import net.osmand.plus.R; import net.osmand.plus.TargetPointsHelper.TargetPoint; -import net.osmand.plus.activities.IntermediatePointsDialog; import net.osmand.plus.activities.MapActivity; +import net.osmand.plus.dialogs.DirectionsDialogs; import net.osmand.plus.helpers.WaypointHelper.LocationPointWrapper; import net.osmand.plus.poi.PoiUIFilter; +import net.osmand.plus.views.controls.DynamicListView.DragIcon; import net.osmand.plus.views.controls.ListDividerShape; import net.osmand.plus.views.controls.StableArrayAdapter; import net.osmand.util.Algorithms; @@ -49,7 +51,12 @@ public class WaypointDialogHelper { private MapActivity mapActivity; private OsmandApplication app; private WaypointHelper waypointHelper; + private PointDeleteCallback dCallback; + private boolean flat; + public interface PointDeleteCallback { + void deleteWaypoint(int position); + } private static class RadiusItem { int type; @@ -59,6 +66,10 @@ public class WaypointDialogHelper { } } + public void setPointDeleteCallback(PointDeleteCallback callback) { + this.dCallback = callback; + } + public WaypointDialogHelper(MapActivity mapActivity) { this.app = mapActivity.getMyApplication(); waypointHelper = this.app.getWaypointHelper(); @@ -154,6 +165,16 @@ public class WaypointDialogHelper { // 0); } + private List getPoints() { + final List points; + if (flat) { + points = new ArrayList(waypointHelper.getAllPoints()); + } else { + points = getStandardPoints(); + } + return points; + } + private List getActivePoints(List points) { List activePoints = new ArrayList<>(); for (Object p : points) { @@ -250,14 +271,13 @@ public class WaypointDialogHelper { final boolean edit, final List deletedPoints, final MapActivity ctx, final int[] running, final boolean flat, final boolean nightMode) { - final List points; - if (flat) { - points = new ArrayList(waypointHelper.getAllPoints()); - } else { - points = getPoints(); - } + this.flat = flat; + + final List points = getPoints(); List activePoints = getActivePoints(points); + final WaypointDialogHelper helper = this; + return new StableArrayAdapter(ctx, R.layout.waypoint_reached, R.id.title, points, activePoints) { @@ -306,7 +326,7 @@ public class WaypointDialogHelper { v = ctx.getLayoutInflater().inflate(R.layout.card_bottom_divider, null); } else if (obj instanceof LocationPointWrapper) { LocationPointWrapper point = (LocationPointWrapper) obj; - v = updateWaypointItemView(edit, deletedPoints, app, ctx, v, point, this, + v = updateWaypointItemView(edit, deletedPoints, app, ctx, helper, v, point, this, nightMode, flat); AndroidUtils.setListItemBackground(mapActivity, v, nightMode); } @@ -317,7 +337,8 @@ public class WaypointDialogHelper { public static View updateWaypointItemView(final boolean edit, final List deletedPoints, - final OsmandApplication app, final Activity ctx, View v, + final OsmandApplication app, final Activity ctx, + final WaypointDialogHelper helper, View v, final LocationPointWrapper point, final ArrayAdapter adapter, final boolean nightMode, final boolean flat) { @@ -325,9 +346,9 @@ public class WaypointDialogHelper { v = ctx.getLayoutInflater().inflate(R.layout.waypoint_reached, null); } updatePointInfoView(app, ctx, v, point, true, nightMode, edit); - View more = v.findViewById(R.id.all_points); - View move = v.findViewById(R.id.info_move); - View remove = v.findViewById(R.id.info_close); + final View more = v.findViewById(R.id.all_points); + final View move = v.findViewById(R.id.info_move); + final View remove = v.findViewById(R.id.info_close); if (!edit) { remove.setVisibility(View.GONE); move.setVisibility(View.GONE); @@ -342,8 +363,31 @@ public class WaypointDialogHelper { more.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { - //hideDashboard(); - IntermediatePointsDialog.openIntermediatePointsDialog(ctx, app, true); + final PopupMenu optionsMenu = new PopupMenu(ctx, more); + DirectionsDialogs.setupPopUpMenuIcon(optionsMenu); + MenuItem item; + item = optionsMenu.getMenu().add( + R.string.intermediate_items_sort_by_distance).setIcon(app.getIconsCache(). + getContentIcon(R.drawable.ic_sort_waypoint_dark)); + item.setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() { + @Override + public boolean onMenuItemClick(MenuItem item) { + // sort + //IntermediatePointsDialog.openIntermediatePointsDialog(ctx, app, true); + return true; + } + }); + item = optionsMenu.getMenu().add( + R.string.switch_start_finish).setIcon(app.getIconsCache(). + getContentIcon(R.drawable.ic_action_undo_dark)); + item.setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() { + @Override + public boolean onMenuItemClick(MenuItem item) { + // switch start & finish + return true; + } + }); + optionsMenu.show(); } }); } else { @@ -352,6 +396,25 @@ public class WaypointDialogHelper { more.setVisibility(View.GONE); ((ImageView) move).setImageDrawable(app.getIconsCache().getContentIcon( R.drawable.ic_flat_list_dark, !nightMode)); + move.setTag(new DragIcon() { + @Override + public void onClick() { + final PopupMenu optionsMenu = new PopupMenu(ctx, move); + DirectionsDialogs.setupPopUpMenuIcon(optionsMenu); + MenuItem item; + item = optionsMenu.getMenu().add( + R.string.shared_string_delete).setIcon(app.getIconsCache(). + getContentIcon(R.drawable.ic_action_remove_dark)); + item.setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() { + @Override + public boolean onMenuItemClick(MenuItem item) { + deletePoint(app, adapter, helper, point, deletedPoints, true); + return true; + } + }); + optionsMenu.show(); + } + }); } } else { remove.setVisibility(View.VISIBLE); @@ -362,22 +425,40 @@ public class WaypointDialogHelper { remove.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { - ArrayList arr = new ArrayList<>(); - arr.add(point); - app.getWaypointHelper().removeVisibleLocationPoint(arr); - - deletedPoints.add(point); - if (adapter != null) { - adapter.setNotifyOnChange(false); - adapter.remove(point); - adapter.notifyDataSetChanged(); - } + deletePoint(app, adapter, helper, point, deletedPoints, true); } }); } return v; } + public static void deletePoint(final OsmandApplication app, final ArrayAdapter adapter, + final WaypointDialogHelper helper, + final Object item, + final List deletedPoints, + final boolean needCallback) { + + if (item instanceof LocationPointWrapper && adapter != null) { + LocationPointWrapper point = (LocationPointWrapper) item; + if (point.type == WaypointHelper.TARGETS && adapter instanceof StableArrayAdapter) { + StableArrayAdapter stableAdapter = (StableArrayAdapter) adapter; + if (helper != null && helper.dCallback != null && needCallback) { + helper.dCallback.deleteWaypoint(stableAdapter.getPosition(item)); + } + } else { + ArrayList arr = new ArrayList<>(); + arr.add(point); + app.getWaypointHelper().removeVisibleLocationPoint(arr); + + deletedPoints.add(point); + + adapter.setNotifyOnChange(false); + adapter.remove(point); + adapter.notifyDataSetChanged(); + } + } + } + protected View createItemForRadiusProximity(final FragmentActivity ctx, final int type, final int[] running, final int position, final ArrayAdapter thisAdapter, boolean nightMode) { @@ -603,8 +684,8 @@ public class WaypointDialogHelper { return str; } - protected List getPoints() { - final List points = new ArrayList(); + protected List getStandardPoints() { + final List points = new ArrayList<>(); boolean rc = waypointHelper.isRouteCalculated(); for (int i = 0; i < WaypointHelper.MAX; i++) { List tp = waypointHelper.getWaypoints(i); diff --git a/OsmAnd/src/net/osmand/plus/mapcontextmenu/MapContextMenuFragment.java b/OsmAnd/src/net/osmand/plus/mapcontextmenu/MapContextMenuFragment.java index a6163d1003..dbe811f5e5 100644 --- a/OsmAnd/src/net/osmand/plus/mapcontextmenu/MapContextMenuFragment.java +++ b/OsmAnd/src/net/osmand/plus/mapcontextmenu/MapContextMenuFragment.java @@ -12,7 +12,6 @@ import android.support.v4.app.FragmentActivity; import android.support.v4.app.FragmentManager; import android.util.TypedValue; import android.view.GestureDetector; -import android.view.GestureDetector.OnGestureListener; import android.view.LayoutInflater; import android.view.MotionEvent; import android.view.VelocityTracker; @@ -45,6 +44,7 @@ import net.osmand.plus.mapcontextmenu.MenuController.TitleButtonController; import net.osmand.plus.mapcontextmenu.MenuController.TitleProgressController; import net.osmand.plus.views.AnimateDraggingMapThread; import net.osmand.plus.views.OsmandMapTileView; +import net.osmand.plus.views.controls.SingleTapConfirm; import net.osmand.util.Algorithms; import static android.util.TypedValue.COMPLEX_UNIT_DIP; @@ -98,41 +98,6 @@ public class MapContextMenuFragment extends Fragment implements DownloadEvents { private int screenOrientation; - private class SingleTapConfirm implements OnGestureListener { - - @Override - public boolean onDown(MotionEvent e) { - return false; - } - - @Override - public void onShowPress(MotionEvent e) { - - } - - @Override - public boolean onSingleTapUp(MotionEvent e) { - return true; - } - - @Override - public boolean onScroll(MotionEvent e1, MotionEvent e2, float distanceX, float distanceY) { - return false; - } - - @Override - public void onLongPress(MotionEvent e) { - - } - - @Override - public boolean onFling(MotionEvent e1, MotionEvent e2, float velocityX, float velocityY) { - return false; - } - - - } - @TargetApi(Build.VERSION_CODES.HONEYCOMB) @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, diff --git a/OsmAnd/src/net/osmand/plus/views/controls/DynamicListView.java b/OsmAnd/src/net/osmand/plus/views/controls/DynamicListView.java index 2c7f6efe07..741bdce1d2 100644 --- a/OsmAnd/src/net/osmand/plus/views/controls/DynamicListView.java +++ b/OsmAnd/src/net/osmand/plus/views/controls/DynamicListView.java @@ -32,6 +32,8 @@ import android.support.annotation.NonNull; import android.support.v4.view.ViewCompat; import android.util.AttributeSet; import android.util.DisplayMetrics; +import android.util.Log; +import android.view.GestureDetector; import android.view.MotionEvent; import android.view.View; import android.view.ViewGroup; @@ -46,7 +48,6 @@ import java.util.List; public class DynamicListView extends ObservableListView { - public final String TAG_DRAG_ICON = "DragIcon"; protected final int SMOOTH_SCROLL_AMOUNT_AT_EDGE = 15; protected final int MOVE_DURATION = 150; @@ -82,6 +83,13 @@ public class DynamicListView extends ObservableListView { private boolean mIsWaitingForScrollFinish = false; private int mScrollState = OnScrollListener.SCROLL_STATE_IDLE; + private GestureDetector singleTapDetector; + private DragIcon tag; + + public interface DragIcon { + void onClick(); + } + public DynamicListView(Context context) { super(context); init(context); @@ -101,6 +109,7 @@ public class DynamicListView extends ObservableListView { setOnScrollListener(mScrollListener); DisplayMetrics metrics = context.getResources().getDisplayMetrics(); mSmoothScrollAmountAtEdge = (int) (SMOOTH_SCROLL_AMOUNT_AT_EDGE / metrics.density); + singleTapDetector = new GestureDetector(context, new SingleTapConfirm()); } public void setDynamicListViewCallbacks(DynamicListViewCallbacks callbacks) { @@ -249,7 +258,7 @@ public class DynamicListView extends ObservableListView { // Draw dividers StableArrayAdapter stableAdapter = getStableAdapter(); - if (stableAdapter != null && stableAdapter.hasDividers()) { + if (getDivider() == null && stableAdapter != null && stableAdapter.hasDividers()) { List dividers = stableAdapter.getDividers(); final int count = getChildCount(); @@ -296,20 +305,28 @@ public class DynamicListView extends ObservableListView { @Override public boolean onTouchEvent(@NonNull MotionEvent event) { + if (singleTapDetector.onTouchEvent(event)) { + if (tag != null) { + tag.onClick(); + } + touchEventsCancelled(); + return true; + } + switch (event.getAction() & MotionEvent.ACTION_MASK) { case MotionEvent.ACTION_DOWN: if (!mCellIsMobile && mHoverCell == null) { - mDownX = (int) event.getX(); - mDownY = (int) event.getY(); - mActivePointerId = event.getPointerId(0); - // Find the view that the user pressed their finger down on. - View v = findViewAtPositionWithTag(getRootView(), (int) event.getRawX(), (int) event.getRawY(), TAG_DRAG_ICON); + View v = findViewAtPositionWithDragIconTag(getRootView(), (int) event.getRawX(), (int) event.getRawY()); - // If the view contains a tag set to "DragIcon", it means that the user wants to + // If the view contains a tag set to "DragIcon" class, it means that the user wants to // reorder the list item. - if ((v != null) && (v.getTag() != null) && (v.getTag().equals(TAG_DRAG_ICON))) { + if ((v != null) && (v.getTag() != null) && (v.getTag() instanceof DragIcon)) { + mDownX = (int) event.getX(); + mDownY = (int) event.getY(); + mActivePointerId = event.getPointerId(0); mTotalOffset = 0; + tag = (DragIcon) v.getTag(); int position = pointToPosition(mDownX, mDownY); if (position != INVALID_POSITION) { @@ -564,6 +581,7 @@ public class DynamicListView extends ObservableListView { mBelowItemId = INVALID_ID; setAllVisible(); mHoverCell = null; + tag = null; setEnabled(true); invalidate(); processSwapped(); @@ -718,7 +736,7 @@ public class DynamicListView extends ObservableListView { * @param y The Y location to be tested. * @return Returns the most inner view that contains the XY coordinate or null if no view could be found. */ - private View findViewAtPositionWithTag(View v, int x, int y, String tag) { + private View findViewAtPositionWithDragIconTag(View v, int x, int y) { View vXY = null; if (v instanceof ViewGroup) { @@ -732,9 +750,9 @@ public class DynamicListView extends ObservableListView { if ((x >= loc[0] && (x <= (loc[0] + c.getWidth()))) && (y >= loc[1] && (y <= (loc[1] + c.getHeight())))) { vXY = c; - View viewAtPosition = findViewAtPositionWithTag(c, x, y, tag); + View viewAtPosition = findViewAtPositionWithDragIconTag(c, x, y); - if ((viewAtPosition != null) && (viewAtPosition.getTag() != null) && viewAtPosition.getTag().equals(tag)) { + if ((viewAtPosition != null) && (viewAtPosition.getTag() != null) && viewAtPosition.getTag() instanceof DragIcon) { vXY = viewAtPosition; break; } diff --git a/OsmAnd/src/net/osmand/plus/views/controls/SingleTapConfirm.java b/OsmAnd/src/net/osmand/plus/views/controls/SingleTapConfirm.java new file mode 100644 index 0000000000..bbda5f2a72 --- /dev/null +++ b/OsmAnd/src/net/osmand/plus/views/controls/SingleTapConfirm.java @@ -0,0 +1,37 @@ +package net.osmand.plus.views.controls; + +import android.view.GestureDetector; +import android.view.MotionEvent; + +public class SingleTapConfirm implements GestureDetector.OnGestureListener { + + @Override + public boolean onDown(MotionEvent e) { + return false; + } + + @Override + public void onShowPress(MotionEvent e) { + + } + + @Override + public boolean onSingleTapUp(MotionEvent e) { + return true; + } + + @Override + public boolean onScroll(MotionEvent e1, MotionEvent e2, float distanceX, float distanceY) { + return false; + } + + @Override + public void onLongPress(MotionEvent e) { + + } + + @Override + public boolean onFling(MotionEvent e1, MotionEvent e2, float velocityX, float velocityY) { + return false; + } +} \ No newline at end of file diff --git a/OsmAnd/src/net/osmand/plus/views/controls/SwipeDismissListViewTouchListener.java b/OsmAnd/src/net/osmand/plus/views/controls/SwipeDismissListViewTouchListener.java index 8aa5c84d42..c4b65ab3be 100644 --- a/OsmAnd/src/net/osmand/plus/views/controls/SwipeDismissListViewTouchListener.java +++ b/OsmAnd/src/net/osmand/plus/views/controls/SwipeDismissListViewTouchListener.java @@ -472,20 +472,18 @@ public class SwipeDismissListViewTouchListener implements View.OnTouchListener { * Delete the list item at the specified position. This will animate the item sliding out of the * list and then collapsing until it vanished (same as if the user slides out an item). *

- * NOTE: If you are using list headers, be aware, that the position argument must take care of - * them. Meaning 0 references the first list header. So if you want to delete the first list - * item, you have to pass the number of list headers as {@code position}. Most of the times - * that shouldn't be a problem, since you most probably will evaluate the position which should - * be deleted in a way, that respects the list headers. */ public void delete(int position) { if (mCallbacks == null) { throw new IllegalStateException("You must set an OnDismissCallback, before deleting items."); } - if (position < 0 || position >= mListView.getCount()) { - throw new IndexOutOfBoundsException(String.format("Tried to delete item %d. #items in list: %d", position, mListView.getCount())); + + int pos = position + mListView.getHeaderViewsCount(); + + if (pos < 0 || pos >= mListView.getCount()) { + throw new IndexOutOfBoundsException(String.format("Tried to delete item %d. #items in list: %d", pos, mListView.getCount())); } - View childView = mListView.getChildAt(position - mListView.getFirstVisiblePosition()); + View childView = mListView.getChildAt(pos - mListView.getFirstVisiblePosition()); View view = null; if (mSwipingLayout > 0) { view = childView.findViewById(mSwipingLayout); From c61843efde7a629c368a33c8781e8eada62a060c Mon Sep 17 00:00:00 2001 From: CJTmmr Date: Sun, 10 Jan 2016 23:24:14 +0100 Subject: [PATCH 11/32] Translated using Weblate (Dutch) Currently translated at 100.0% (1878 of 1878 strings) --- OsmAnd/res/values-nl/strings.xml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-nl/strings.xml b/OsmAnd/res/values-nl/strings.xml index 410fdf0c91..be5bad17b4 100644 --- a/OsmAnd/res/values-nl/strings.xml +++ b/OsmAnd/res/values-nl/strings.xml @@ -1,4 +1,5 @@ - + + Configureer scherm Toon rijstroken @@ -2162,4 +2163,5 @@ Item verwijderd items verwijderd Alles terugzetten - \ No newline at end of file + Verberg iconen + From d475fe7b532a4c59e8a923096598f54d3965f77c Mon Sep 17 00:00:00 2001 From: Adriano Rosa Date: Sun, 10 Jan 2016 14:31:05 +0100 Subject: [PATCH 12/32] Translated using Weblate (Portuguese (Brazil)) Currently translated at 100.0% (1878 of 1878 strings) --- OsmAnd/res/values-pt-rBR/strings.xml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-pt-rBR/strings.xml b/OsmAnd/res/values-pt-rBR/strings.xml index d2b7770e2f..2375c1d2da 100644 --- a/OsmAnd/res/values-pt-rBR/strings.xml +++ b/OsmAnd/res/values-pt-rBR/strings.xml @@ -1,4 +1,5 @@ -Meus locais + +Meus locais dias atrás Ver Pista de preparação @@ -1990,4 +1991,5 @@ Item apagado itens apagados DESFAZER TUDO - \ No newline at end of file + Ocultar ícones + From ebd8a118fb88bdb3c6cbc86e32be589e2353001e Mon Sep 17 00:00:00 2001 From: jan madsen Date: Mon, 11 Jan 2016 08:41:05 +0100 Subject: [PATCH 13/32] Translated using Weblate (Danish) Currently translated at 100.0% (1878 of 1878 strings) --- OsmAnd/res/values-da/strings.xml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-da/strings.xml b/OsmAnd/res/values-da/strings.xml index 628d702b3a..6d5145c420 100644 --- a/OsmAnd/res/values-da/strings.xml +++ b/OsmAnd/res/values-da/strings.xml @@ -1,4 +1,5 @@ - + + Overvej at købe Højdekurve udvidelsen (\'Contour lines\') på Google Play for at støtte den videre udvikling. Optag video Optag audio @@ -2224,4 +2225,5 @@ Emne slettet Emner slettet FORTRYD ALLE - \ No newline at end of file + Skjul ikoner + From 5bdcd3b4368c1576009377f575d54282e9e2b5f3 Mon Sep 17 00:00:00 2001 From: Alexey Kulish Date: Tue, 12 Jan 2016 19:07:38 +0300 Subject: [PATCH 14/32] Added 'Sort door by door' menu item to Waypoints --- .../osmand/plus/dashboard/DashboardOnMap.java | 1 - .../plus/helpers/WaypointDialogHelper.java | 109 +++++++++++++++++- 2 files changed, 103 insertions(+), 7 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/dashboard/DashboardOnMap.java b/OsmAnd/src/net/osmand/plus/dashboard/DashboardOnMap.java index c1f3373e18..8c5bdff6c9 100644 --- a/OsmAnd/src/net/osmand/plus/dashboard/DashboardOnMap.java +++ b/OsmAnd/src/net/osmand/plus/dashboard/DashboardOnMap.java @@ -1198,7 +1198,6 @@ public class DashboardOnMap implements ObservableScrollViewCallbacks, DynamicLis if ((DashboardType.WAYPOINTS == visibleType || DashboardType.WAYPOINTS_FLAT == visibleType) && listAdapter != null && listAdapter instanceof StableArrayAdapter) { StableArrayAdapter stableAdapter = (StableArrayAdapter) listAdapter; - getMyApplication().getWaypointHelper().removeVisibleLocationPoint(deletedPoints); waypointDialogHelper.reloadListAdapter(stableAdapter); if (listView instanceof DynamicListView) { DynamicListView dynamicListView = (DynamicListView) listView; diff --git a/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java b/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java index f526b0ed6b..17e276961f 100644 --- a/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java +++ b/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java @@ -1,6 +1,7 @@ package net.osmand.plus.helpers; import android.app.Activity; +import android.app.ProgressDialog; import android.content.Context; import android.content.DialogInterface; import android.content.DialogInterface.OnClickListener; @@ -24,6 +25,7 @@ import android.widget.TextView; import net.osmand.AndroidUtils; import net.osmand.Location; +import net.osmand.TspAnt; import net.osmand.data.FavouritePoint; import net.osmand.data.LatLon; import net.osmand.data.LocationPoint; @@ -31,6 +33,7 @@ import net.osmand.data.PointDescription; import net.osmand.plus.OsmAndFormatter; import net.osmand.plus.OsmandApplication; import net.osmand.plus.R; +import net.osmand.plus.TargetPointsHelper; import net.osmand.plus.TargetPointsHelper.TargetPoint; import net.osmand.plus.activities.MapActivity; import net.osmand.plus.dialogs.DirectionsDialogs; @@ -52,7 +55,9 @@ public class WaypointDialogHelper { private OsmandApplication app; private WaypointHelper waypointHelper; private PointDeleteCallback dCallback; + private boolean flat; + private List deletedPoints; public interface PointDeleteCallback { void deleteWaypoint(int position); @@ -272,6 +277,7 @@ public class WaypointDialogHelper { final MapActivity ctx, final int[] running, final boolean flat, final boolean nightMode) { this.flat = flat; + this.deletedPoints = deletedPoints; final List points = getPoints(); List activePoints = getActivePoints(points); @@ -372,8 +378,8 @@ public class WaypointDialogHelper { item.setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() { @Override public boolean onMenuItemClick(MenuItem item) { - // sort - //IntermediatePointsDialog.openIntermediatePointsDialog(ctx, app, true); + // sort door-to-door + sortAllTargets(app, ctx); return true; } }); @@ -433,10 +439,10 @@ public class WaypointDialogHelper { } public static void deletePoint(final OsmandApplication app, final ArrayAdapter adapter, - final WaypointDialogHelper helper, - final Object item, - final List deletedPoints, - final boolean needCallback) { + final WaypointDialogHelper helper, + final Object item, + final List deletedPoints, + final boolean needCallback) { if (item instanceof LocationPointWrapper && adapter != null) { LocationPointWrapper point = (LocationPointWrapper) item; @@ -454,6 +460,11 @@ public class WaypointDialogHelper { adapter.setNotifyOnChange(false); adapter.remove(point); + if (adapter instanceof StableArrayAdapter) { + StableArrayAdapter stableAdapter = (StableArrayAdapter) adapter; + stableAdapter.getObjects().remove(item); + stableAdapter.refreshData(); + } adapter.notifyDataSetChanged(); } } @@ -650,6 +661,8 @@ public class WaypointDialogHelper { } public void reloadListAdapter(ArrayAdapter listAdapter) { + mapActivity.getMyApplication().getWaypointHelper().removeVisibleLocationPoint(deletedPoints); + listAdapter.setNotifyOnChange(false); listAdapter.clear(); List points = getPoints(); @@ -783,4 +796,88 @@ public class WaypointDialogHelper { */ } + public static void sortAllTargets(final OsmandApplication app, final Activity activity) { + + new AsyncTask() { + + ProgressDialog dlg = null; + long startDialogTime = 0; + List intermediates; + + protected void onPreExecute() { + startDialogTime = System.currentTimeMillis(); + dlg = new ProgressDialog(activity); + dlg.setTitle(""); + dlg.setMessage(activity.getResources().getString(R.string.intermediate_items_sort_by_distance)); + dlg.show(); + } + + protected int[] doInBackground(Void[] params) { + + TargetPointsHelper targets = app.getTargetPointsHelper(); + intermediates = targets.getIntermediatePointsWithTarget(); + + Location cll = app.getLocationProvider().getLastKnownLocation(); + ArrayList lt = new ArrayList<>(intermediates); + TargetPoint start; + + if (cll != null) { + LatLon ll = new LatLon(cll.getLatitude(), cll.getLongitude()); + start = TargetPoint.create(ll, null); + } else if (app.getTargetPointsHelper().getPointToStart() != null) { + TargetPoint ps = app.getTargetPointsHelper().getPointToStart(); + LatLon ll = new LatLon(ps.getLatitude(), ps.getLongitude()); + start = TargetPoint.create(ll, null); + } else { + start = lt.get(0); + } + TargetPoint end = lt.remove(lt.size() - 1); + ArrayList al = new ArrayList<>(); + for (TargetPoint p : lt) { + al.add(p.point); + } + return new TspAnt().readGraph(al, start.point, end.point).solve(); + } + + protected void onPostExecute(int[] result) { + if (dlg != null) { + long t = System.currentTimeMillis(); + if (t - startDialogTime < 500) { + app.runInUIThread(new Runnable() { + @Override + public void run() { + dlg.dismiss(); + } + }, 500 - (t - startDialogTime)); + } else { + dlg.dismiss(); + } + } + + List alocs = new ArrayList<>(); + for (int i : result) { + if (i > 0) { + TargetPoint loc = intermediates.get(i - 1); + alocs.add(loc); + } + } + intermediates.clear(); + intermediates.addAll(alocs); + + TargetPointsHelper targets = app.getTargetPointsHelper(); + List cur = targets.getIntermediatePointsWithTarget(); + boolean eq = true; + for (int j = 0; j < cur.size() && j < intermediates.size(); j++) { + if (cur.get(j) != intermediates.get(j)) { + eq = false; + break; + } + } + if (!eq) { + targets.reorderAllTargetPoints(intermediates, true); + } + } + + }.execute(); + } } \ No newline at end of file From 0cda789a5628574de0a8bb7d7d00cdf868ad0dae Mon Sep 17 00:00:00 2001 From: ezjerry liao Date: Sun, 10 Jan 2016 17:40:25 +0100 Subject: [PATCH 15/32] Translated using Weblate (Chinese (Taiwan)) Currently translated at 100.0% (1878 of 1878 strings) --- OsmAnd/res/values-zh-rTW/strings.xml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-zh-rTW/strings.xml b/OsmAnd/res/values-zh-rTW/strings.xml index e84a9a9e12..ffd2a733d6 100644 --- a/OsmAnd/res/values-zh-rTW/strings.xml +++ b/OsmAnd/res/values-zh-rTW/strings.xml @@ -1,4 +1,5 @@ - + + 選擇道路的色彩調配: 道路的色彩調配 顯示目的地方向 @@ -2070,4 +2071,5 @@ 項目已刪除 項目已刪除 全部取消 - \ No newline at end of file + 隱藏圖示 + From c3366d673dbdd84ea259a5181cdea1ce39e03a31 Mon Sep 17 00:00:00 2001 From: jan madsen Date: Tue, 12 Jan 2016 17:09:52 +0100 Subject: [PATCH 16/32] Translated using Weblate (Danish) Currently translated at 100.0% (2378 of 2378 strings) --- OsmAnd/res/values-da/phrases.xml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/OsmAnd/res/values-da/phrases.xml b/OsmAnd/res/values-da/phrases.xml index 007ea2486e..350337a40c 100644 --- a/OsmAnd/res/values-da/phrases.xml +++ b/OsmAnd/res/values-da/phrases.xml @@ -2639,4 +2639,7 @@ Under opførelse +Hæveautomat: ja + Hæveautomat: nej + From 1220b6600413abfa225c4bf59b34c10a0098bd29 Mon Sep 17 00:00:00 2001 From: Leif Larsson Date: Tue, 12 Jan 2016 16:30:05 +0100 Subject: [PATCH 17/32] Translated using Weblate (Swedish) Currently translated at 99.2% (1863 of 1878 strings) --- OsmAnd/res/values-sv/strings.xml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-sv/strings.xml b/OsmAnd/res/values-sv/strings.xml index 9d7e9ddc51..42fcd9759c 100644 --- a/OsmAnd/res/values-sv/strings.xml +++ b/OsmAnd/res/values-sv/strings.xml @@ -1,4 +1,5 @@ - + + För att låsa upp skärmen tryck på låsikonen Välj land Välj stad @@ -2063,4 +2064,5 @@ post raderad poster raderade ÅNGRA ALLA - \ No newline at end of file + Dölj ikonerna + From 9d381554e1796d210eab929ab4b1283ccdbcfa5a Mon Sep 17 00:00:00 2001 From: Roberto GEB Date: Tue, 12 Jan 2016 17:26:04 +0100 Subject: [PATCH 18/32] Translated using Weblate (Spanish) Currently translated at 99.9% (2376 of 2378 strings) --- OsmAnd/res/values-es/phrases.xml | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/OsmAnd/res/values-es/phrases.xml b/OsmAnd/res/values-es/phrases.xml index 5e904a43b5..a8b87ad8ba 100644 --- a/OsmAnd/res/values-es/phrases.xml +++ b/OsmAnd/res/values-es/phrases.xml @@ -2600,4 +2600,20 @@ Nombre oficial - +Señal ďe Dique + Delfín + + Inscripción: N + Inscripción: NO + Inscripción: O + Inscripción: SO + Inscripción: S + Inscripción: SE + Inscripción: E + Inscripción: NE + + En construcción + Cajero automático: no + +Cajero automático: sí + From eca74dab64843f81fb0ff84c454cb3ae295259cc Mon Sep 17 00:00:00 2001 From: Alexey Kulish Date: Tue, 12 Jan 2016 20:16:06 +0300 Subject: [PATCH 19/32] Fix drag icon --- OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java b/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java index 17e276961f..30aec6ce18 100644 --- a/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java +++ b/OsmAnd/src/net/osmand/plus/helpers/WaypointDialogHelper.java @@ -401,7 +401,7 @@ public class WaypointDialogHelper { move.setVisibility(View.VISIBLE); more.setVisibility(View.GONE); ((ImageView) move).setImageDrawable(app.getIconsCache().getContentIcon( - R.drawable.ic_flat_list_dark, !nightMode)); + R.drawable.ic_action_reorder, !nightMode)); move.setTag(new DragIcon() { @Override public void onClick() { From a82240fe1c3400c57db01bfb08b0159f6922a17d Mon Sep 17 00:00:00 2001 From: jan madsen Date: Tue, 12 Jan 2016 17:07:27 +0100 Subject: [PATCH 20/32] Translated using Weblate (Danish) Currently translated at 100.0% (1879 of 1879 strings) --- OsmAnd/res/values-da/strings.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/OsmAnd/res/values-da/strings.xml b/OsmAnd/res/values-da/strings.xml index 6d5145c420..4b1fabc68b 100644 --- a/OsmAnd/res/values-da/strings.xml +++ b/OsmAnd/res/values-da/strings.xml @@ -2226,4 +2226,5 @@ Emner slettet FORTRYD ALLE Skjul ikoner + Skift start & slut From 5750e699cd3f37a9d4ea20e5e955b3ed49a06a74 Mon Sep 17 00:00:00 2001 From: Franco Date: Tue, 12 Jan 2016 20:09:18 +0100 Subject: [PATCH 21/32] Translated using Weblate (Argentinean Spanish) Currently translated at 100.0% (2378 of 2378 strings) --- OsmAnd/res/values-es-rAR/phrases.xml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/OsmAnd/res/values-es-rAR/phrases.xml b/OsmAnd/res/values-es-rAR/phrases.xml index 6642f9a26e..04639fe348 100644 --- a/OsmAnd/res/values-es-rAR/phrases.xml +++ b/OsmAnd/res/values-es-rAR/phrases.xml @@ -2596,4 +2596,22 @@ Nombre oficial +Dique náutico + Duque de alba (náutico) + + Cartel: Compartimento forestal + Cartel: Parcela forestal + Inscripción: N + Inscripción: NO + Inscripción: O + Inscripción: SO + Inscripción: S + Inscripción: SE + Inscripción: E + Inscripción: NE + + En construcción + Con cajero automático + Sin cajero automático + From 0fdfe30fabdc53fee9548fb8032f7634b0d05dbf Mon Sep 17 00:00:00 2001 From: Franco Date: Tue, 12 Jan 2016 19:53:01 +0100 Subject: [PATCH 22/32] Translated using Weblate (Argentinean Spanish) Currently translated at 100.0% (1879 of 1879 strings) --- OsmAnd/res/values-es-rAR/strings.xml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-es-rAR/strings.xml b/OsmAnd/res/values-es-rAR/strings.xml index 791c65bcc0..d182ef950c 100644 --- a/OsmAnd/res/values-es-rAR/strings.xml +++ b/OsmAnd/res/values-es-rAR/strings.xml @@ -1,4 +1,5 @@ - + + Ocultar números de casa Falló al copiar archivos @@ -2044,4 +2045,6 @@ Elemento borrado elementos borrados DESHACER TODO - \ No newline at end of file + Ocultar iconos + Cambiar inicio y final + From 67ced693390f47eb44476a94d3d215559f86947c Mon Sep 17 00:00:00 2001 From: CJTmmr Date: Tue, 12 Jan 2016 16:20:10 +0100 Subject: [PATCH 23/32] Translated using Weblate (Dutch) Currently translated at 100.0% (1879 of 1879 strings) --- OsmAnd/res/values-nl/strings.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/OsmAnd/res/values-nl/strings.xml b/OsmAnd/res/values-nl/strings.xml index be5bad17b4..2c838f39de 100644 --- a/OsmAnd/res/values-nl/strings.xml +++ b/OsmAnd/res/values-nl/strings.xml @@ -2164,4 +2164,5 @@ items verwijderd Alles terugzetten Verberg iconen + Verwissel start en einde From f56b3410f8daa33f63e14bf49a21da449e064b64 Mon Sep 17 00:00:00 2001 From: sonora Date: Wed, 13 Jan 2016 01:59:02 +0100 Subject: [PATCH 24/32] some string improvements --- OsmAnd/res/values-de/strings.xml | 5 +++-- OsmAnd/res/values/strings.xml | 6 +++--- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/OsmAnd/res/values-de/strings.xml b/OsmAnd/res/values-de/strings.xml index c598cbaaaf..a07cfb70e1 100644 --- a/OsmAnd/res/values-de/strings.xml +++ b/OsmAnd/res/values-de/strings.xml @@ -1,4 +1,4 @@ - + Keine Adresse bekannt Nähe Regionen @@ -1995,4 +1995,5 @@ Typ Startpunkt Alles rückgängig machen - \ No newline at end of file + Startpunkt und Ziel vertauschen + \ No newline at end of file diff --git a/OsmAnd/res/values/strings.xml b/OsmAnd/res/values/strings.xml index c882ac8ffd..e2abab01ca 100644 --- a/OsmAnd/res/values/strings.xml +++ b/OsmAnd/res/values/strings.xml @@ -1,4 +1,4 @@ - + - Switch start & finish - Hide icons + Reverse starting point & destination + Hide POI icons Item deleted items deleted UNDO ALL From 553f846943583508fe68ece5787ac5d6321e31bd Mon Sep 17 00:00:00 2001 From: jf-simon Date: Tue, 12 Jan 2016 23:00:04 +0100 Subject: [PATCH 25/32] Translated using Weblate (German) Currently translated at 99.8% (1877 of 1879 strings) --- OsmAnd/res/values-de/strings.xml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-de/strings.xml b/OsmAnd/res/values-de/strings.xml index c598cbaaaf..fd333cc08d 100644 --- a/OsmAnd/res/values-de/strings.xml +++ b/OsmAnd/res/values-de/strings.xml @@ -1,4 +1,5 @@ - + + Keine Adresse bekannt Nähe Regionen @@ -1995,4 +1996,6 @@ Typ Startpunkt Alles rückgängig machen - \ No newline at end of file + Symbole ausblenden + Tausche Start & Ende + From bae02fe594dc1301870aa53ddcdc135f9187cc7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A1=D0=B0=D1=88=D0=B0=20=D0=9F=D0=B5=D1=82=D1=80=D0=BE?= =?UTF-8?q?=D0=B2=D0=B8=D1=9B?= Date: Tue, 12 Jan 2016 21:20:04 +0100 Subject: [PATCH 26/32] Translated using Weblate (Serbian) Currently translated at 53.3% (1002 of 1879 strings) --- OsmAnd/res/values-sr/strings.xml | 50 ++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/OsmAnd/res/values-sr/strings.xml b/OsmAnd/res/values-sr/strings.xml index 9ab1b3d82f..61c8e985df 100644 --- a/OsmAnd/res/values-sr/strings.xml +++ b/OsmAnd/res/values-sr/strings.xml @@ -1019,4 +1019,54 @@ Избегавај неасвалтиране путеве Избегавај неасвалтиране путеве Одреди/уреди… + Замени полазну и циљну тачку + Сакриј иконице + Означи месец и државу +Седмично + Откажи путању + Могућности приступачности + Подаци ГПС-а + Отворене карте ЕУ-а + Подаци звука/видеа + Да ли сигурно желите да очистите тачку одредишта (и пролазна одредишта)? + Омогући рачунање тачних путања без грешака. Радња је ограничена даљином и спора. + Тачно рачунање путања (споро) + Молим, размислите о куповини Линија обриса из продавнице ради давања подршке даљем развоју програма. + Означи на захтев + Изаберите облик излазног снимка + Облик излазног снимка + Користи склопног снимача за видео + Користи склопног снимача видеа + Користи склопни програм за слике + Користи програм камере + Звук/видео је снимљен. Зауставите снимање притиском на справицу ЗВ-а + Изводи се одређени звучни запис\n%1$s + Отвори програм спољног извођача + Снимак се не може извести + Снимам %1$s %3$s %2$s + Положај за придруживање белешци и даље није одређен. „Користи положај …“ за придруживање белешке одређеном положају + делови + Приказуј путеве према лествици САЦ-а + Приказуј путеве према путањама ОСМЦ-а + + Одредите када ће се приказивати само путне карте: + Само путне карте + Покрени програм у безбедном начину рада (користећи спорији Андроидов код уместо бржег програмског). + Безбедни начин рада + Програм је у безбедном начину рада (онемогућава се у поставкама). + Изаберите образац боја путева: + Образац боја путева + Омогућите прикључак снимања путовања ради коришћења услуга бележења (бележење ГПИксом, праћење положаја на мрежи) + Рачунај могућу приближну путању за велике раздаљине + Молим, омогућите ГПС у поставкама + Услуге бележења путање + Нема пута + Стигли сте на пролазно одредиште + Додај као пролазно одредиште + Пролазно одредиште + Завршна тачка је предалеко од најближег пута. + Напредни начин рада… + Користи компас + Користи компас када правац није препознат на други начин + Избегавај путеве за моторна возила From c160c139ddeed7eb244e9755e5642be70a6eb907 Mon Sep 17 00:00:00 2001 From: Adriano Rosa Date: Tue, 12 Jan 2016 21:49:29 +0100 Subject: [PATCH 27/32] Translated using Weblate (Portuguese (Brazil)) Currently translated at 99.8% (2375 of 2378 strings) --- OsmAnd/res/values-pt-rBR/phrases.xml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/OsmAnd/res/values-pt-rBR/phrases.xml b/OsmAnd/res/values-pt-rBR/phrases.xml index f9723d8988..0a43da758f 100644 --- a/OsmAnd/res/values-pt-rBR/phrases.xml +++ b/OsmAnd/res/values-pt-rBR/phrases.xml @@ -2591,4 +2591,18 @@ Nome oficial +Dique náutico + Inscrição: N + Inscrição: NO + Inscrição: O + Inscrição: SO + Inscrição: S + Inscrição: SE + Inscrição: E + Inscrição: NE + + Em construção + ATM: sim + ATM: não + From 895f3706a85fb5c63af423f2ff2dd5bc195648f5 Mon Sep 17 00:00:00 2001 From: Adriano Rosa Date: Wed, 13 Jan 2016 02:10:27 +0100 Subject: [PATCH 28/32] Translated using Weblate (Portuguese (Brazil)) Currently translated at 100.0% (2378 of 2378 strings) --- OsmAnd/res/values-pt-rBR/phrases.xml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/OsmAnd/res/values-pt-rBR/phrases.xml b/OsmAnd/res/values-pt-rBR/phrases.xml index 0a43da758f..0511ba31d9 100644 --- a/OsmAnd/res/values-pt-rBR/phrases.xml +++ b/OsmAnd/res/values-pt-rBR/phrases.xml @@ -2605,4 +2605,8 @@ ATM: sim ATM: não - +Pôster: compartimento florestal + Pôster: loteamento florestal + Dolphin (náutico) + + From 0b54bd0f45825e5b722673dad1265b87c9fb6665 Mon Sep 17 00:00:00 2001 From: Adriano Rosa Date: Tue, 12 Jan 2016 16:21:17 +0100 Subject: [PATCH 29/32] Translated using Weblate (Portuguese (Brazil)) Currently translated at 100.0% (1879 of 1879 strings) --- OsmAnd/res/values-pt-rBR/strings.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/OsmAnd/res/values-pt-rBR/strings.xml b/OsmAnd/res/values-pt-rBR/strings.xml index 2375c1d2da..8160f0e423 100644 --- a/OsmAnd/res/values-pt-rBR/strings.xml +++ b/OsmAnd/res/values-pt-rBR/strings.xml @@ -1992,4 +1992,5 @@ itens apagados DESFAZER TUDO Ocultar ícones + Alternar iniciar e finalizar From e566c92708775e7c460fb75722ca61130327e26e Mon Sep 17 00:00:00 2001 From: ezjerry liao Date: Tue, 12 Jan 2016 17:09:34 +0100 Subject: [PATCH 30/32] Translated using Weblate (Chinese (Taiwan)) Currently translated at 100.0% (1879 of 1879 strings) --- OsmAnd/res/values-zh-rTW/strings.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/OsmAnd/res/values-zh-rTW/strings.xml b/OsmAnd/res/values-zh-rTW/strings.xml index ffd2a733d6..41d66a255e 100644 --- a/OsmAnd/res/values-zh-rTW/strings.xml +++ b/OsmAnd/res/values-zh-rTW/strings.xml @@ -2072,4 +2072,5 @@ 項目已刪除 全部取消 隱藏圖示 + 切換開始以及結束 From 3b9fe7db247d7a9852ce72cb29941e7dfeb780a8 Mon Sep 17 00:00:00 2001 From: jan madsen Date: Wed, 13 Jan 2016 07:32:00 +0100 Subject: [PATCH 31/32] Translated using Weblate (Danish) Currently translated at 100.0% (1879 of 1879 strings) --- OsmAnd/res/values-da/strings.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-da/strings.xml b/OsmAnd/res/values-da/strings.xml index 4b1fabc68b..d57be4b5b5 100644 --- a/OsmAnd/res/values-da/strings.xml +++ b/OsmAnd/res/values-da/strings.xml @@ -2225,6 +2225,6 @@ Emne slettet Emner slettet FORTRYD ALLE - Skjul ikoner - Skift start & slut + Skjul IP ikoner + Byt rundt på startpunkt & destination From 5efa67eba6e92df7e427ea47033257295b744123 Mon Sep 17 00:00:00 2001 From: Ldm Public Date: Wed, 13 Jan 2016 08:27:06 +0100 Subject: [PATCH 32/32] Translated using Weblate (French) Currently translated at 100.0% (1879 of 1879 strings) --- OsmAnd/res/values-fr/strings.xml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/values-fr/strings.xml b/OsmAnd/res/values-fr/strings.xml index f4ae42242c..4c5d8edbe6 100644 --- a/OsmAnd/res/values-fr/strings.xml +++ b/OsmAnd/res/values-fr/strings.xml @@ -1,4 +1,5 @@ - + + Modifications hors-ligne Toujours utiliser l\'édition hors-ligne @@ -2110,4 +2111,6 @@ Taille de l\'espace de stockage Espace maximum alloué pour tous les enregistrements Type - \ No newline at end of file + Inverser Départ et Destination + Masquer les icônes de PI +