From e7430dcd5b0f9a18db9537b2c492f5b002d9881b Mon Sep 17 00:00:00 2001 From: Dima-1 Date: Thu, 23 Apr 2020 11:46:58 +0300 Subject: [PATCH] Fix strings, refactor --- OsmAnd/res/values-ar/strings.xml | 2 +- OsmAnd/res/values-b+be+Latn/strings.xml | 2 +- OsmAnd/res/values-be/strings.xml | 2 +- OsmAnd/res/values-ca/strings.xml | 2 +- OsmAnd/res/values-cs/strings.xml | 2 +- OsmAnd/res/values-da/strings.xml | 2 +- OsmAnd/res/values-de/strings.xml | 2 +- OsmAnd/res/values-el/strings.xml | 2 +- OsmAnd/res/values-eo/strings.xml | 2 +- OsmAnd/res/values-es-rAR/strings.xml | 2 +- OsmAnd/res/values-es-rUS/strings.xml | 2 +- OsmAnd/res/values-es/strings.xml | 2 +- OsmAnd/res/values-et/strings.xml | 2 +- OsmAnd/res/values-gl/strings.xml | 2 +- OsmAnd/res/values-he/strings.xml | 2 +- OsmAnd/res/values-id/strings.xml | 2 +- OsmAnd/res/values-is/strings.xml | 2 +- OsmAnd/res/values-it/strings.xml | 2 +- OsmAnd/res/values-ka/strings.xml | 2 +- OsmAnd/res/values-lt/strings.xml | 2 +- OsmAnd/res/values-lv/strings.xml | 2 +- OsmAnd/res/values-ml/strings.xml | 2 +- OsmAnd/res/values-nb/strings.xml | 2 +- OsmAnd/res/values-nl/strings.xml | 2 +- OsmAnd/res/values-oc/strings.xml | 2 +- OsmAnd/res/values-pl/strings.xml | 2 +- OsmAnd/res/values-pt-rBR/strings.xml | 2 +- OsmAnd/res/values-pt/strings.xml | 2 +- OsmAnd/res/values-ro/strings.xml | 2 +- OsmAnd/res/values-ru/strings.xml | 2 +- OsmAnd/res/values-sc/strings.xml | 2 +- OsmAnd/res/values-sk/strings.xml | 2 +- OsmAnd/res/values-sl/strings.xml | 2 +- OsmAnd/res/values-sr/strings.xml | 2 +- OsmAnd/res/values-sv/strings.xml | 2 +- OsmAnd/res/values-ta/strings.xml | 2 +- OsmAnd/res/values-tr/strings.xml | 2 +- OsmAnd/res/values-uk/strings.xml | 2 +- OsmAnd/res/values-zh-rCN/strings.xml | 2 +- OsmAnd/res/values-zh-rTW/strings.xml | 2 +- .../chooseplan/ChoosePlanDialogFragment.java | 10 +++++++--- .../net/osmand/plus/inapp/InAppPurchases.java | 16 +--------------- 42 files changed, 48 insertions(+), 58 deletions(-) diff --git a/OsmAnd/res/values-ar/strings.xml b/OsmAnd/res/values-ar/strings.xml index 1473b93b73..8531f871fb 100644 --- a/OsmAnd/res/values-ar/strings.xml +++ b/OsmAnd/res/values-ar/strings.xml @@ -2699,7 +2699,7 @@ سنوي %1$s / شهر %1$.2f %2$s / شهر - وفر %1$s. + وفر %1$s الاشتراك الحالي يجدد شهريا تجديد فصلي diff --git a/OsmAnd/res/values-b+be+Latn/strings.xml b/OsmAnd/res/values-b+be+Latn/strings.xml index 99a2c0c80e..a5a49915b4 100644 --- a/OsmAnd/res/values-b+be+Latn/strings.xml +++ b/OsmAnd/res/values-b+be+Latn/strings.xml @@ -2846,7 +2846,7 @@ Praparcyjnaj pamiacі %4$s MB (Abmiežavańnie Android %5$s MB, Dalvik %6$s MB). Štohod %1$s / miesiac %1$.2f %2$s / miesiac - Aščada %1$s. + Aščada %1$s Dziejnaja padpiska Abnaŭliajecca štomiesiac Abnaŭliajecca štokvartaĺna diff --git a/OsmAnd/res/values-be/strings.xml b/OsmAnd/res/values-be/strings.xml index 1ac9a2a332..504fa380c9 100644 --- a/OsmAnd/res/values-be/strings.xml +++ b/OsmAnd/res/values-be/strings.xml @@ -2919,7 +2919,7 @@ Штогод %1$s / месяц %1$.2f %2$s / месяц - Ашчада %1$s. + Ашчада %1$s Дзейная падпіска Абнаўляецца штомесяц Абнаўляецца штоквартал diff --git a/OsmAnd/res/values-ca/strings.xml b/OsmAnd/res/values-ca/strings.xml index 4a7b09c6c1..70af6407c1 100644 --- a/OsmAnd/res/values-ca/strings.xml +++ b/OsmAnd/res/values-ca/strings.xml @@ -2874,7 +2874,7 @@ Abasta l\'àrea: %1$s x %2$s Anualment %1$s / mes %1$.2f %2$s / mes - Desa %1$s. + Desa %1$s Subscripció actual Renovació mensual Renovació trimestral diff --git a/OsmAnd/res/values-cs/strings.xml b/OsmAnd/res/values-cs/strings.xml index 74ccc1edef..962a29c222 100644 --- a/OsmAnd/res/values-cs/strings.xml +++ b/OsmAnd/res/values-cs/strings.xml @@ -2827,7 +2827,7 @@ Zobrazená oblast: %1$s x %2$s Ročně %1$s / měsíc %1$.2f %2$s / měsíc - Ušetříte %1$s. + Ušetříte %1$s Aktuální předplatné Obnovuje se měsíčně Obnovuje se čtvrtletně diff --git a/OsmAnd/res/values-da/strings.xml b/OsmAnd/res/values-da/strings.xml index 42697f3221..2e7ae0cc0a 100644 --- a/OsmAnd/res/values-da/strings.xml +++ b/OsmAnd/res/values-da/strings.xml @@ -2858,7 +2858,7 @@ Repræsenterer område: %1$s x %2$s Årligt %1$s / måned %1$.2f %2$s / måned - Spar %1$s. + Spar %1$s Nuværende abonnement Fornyes månedligt Fornyes kvartalsvis diff --git a/OsmAnd/res/values-de/strings.xml b/OsmAnd/res/values-de/strings.xml index ea63260ab9..15d384d74c 100644 --- a/OsmAnd/res/values-de/strings.xml +++ b/OsmAnd/res/values-de/strings.xml @@ -2864,7 +2864,7 @@ Lon %2$s Jährlich %1$s / Monat %1$.2f %2$s / Monat - Sparen Sie %1$s. + Sparen Sie %1$s Aktuelles Abonnement Verlängert sich monatlich Verlängert sich vierteljährlich diff --git a/OsmAnd/res/values-el/strings.xml b/OsmAnd/res/values-el/strings.xml index cceaa6d0e4..f18342af5d 100644 --- a/OsmAnd/res/values-el/strings.xml +++ b/OsmAnd/res/values-el/strings.xml @@ -2831,7 +2831,7 @@ Ετήσια %1$s / μήνα %1$.2f %2$s / μήνα - Εξοικονομήστε %1$s. + Εξοικονομήστε %1$s Η τρέχουσα εγγραφή Μηνιαίες ανανεώσεις Τριμηνιαίες ανανεώσεις diff --git a/OsmAnd/res/values-eo/strings.xml b/OsmAnd/res/values-eo/strings.xml index 59a6a36628..db33067366 100644 --- a/OsmAnd/res/values-eo/strings.xml +++ b/OsmAnd/res/values-eo/strings.xml @@ -2844,7 +2844,7 @@ Indikas lokon: %1$s x %2$s" Ĉiujare %1$s / monato %1$,2f %2$s / monato - Ŝparu %1$s. + Ŝparu %1$s Nuna kotizo Reaboni ĉiumonate Reaboni ĉiukvaronjare diff --git a/OsmAnd/res/values-es-rAR/strings.xml b/OsmAnd/res/values-es-rAR/strings.xml index 3ec3bfc10b..5c9d9c236a 100644 --- a/OsmAnd/res/values-es-rAR/strings.xml +++ b/OsmAnd/res/values-es-rAR/strings.xml @@ -2858,7 +2858,7 @@ Lon %2$s Anual %1$s / mes %1$.2f %2$s / mes - Ahorra %1$s. + Ahorra %1$s Suscripción actual Renovar mensualmente Renovar trimestralmente diff --git a/OsmAnd/res/values-es-rUS/strings.xml b/OsmAnd/res/values-es-rUS/strings.xml index 147cbbbad9..336f032e6d 100644 --- a/OsmAnd/res/values-es-rUS/strings.xml +++ b/OsmAnd/res/values-es-rUS/strings.xml @@ -2858,7 +2858,7 @@ Lon %2$s Anual %1$s / mes %1$.2f %2$s / mes - Ahorra %1$s. + Ahorra %1$s Suscripción actual Renovar mensualmente Renovar trimestralmente diff --git a/OsmAnd/res/values-es/strings.xml b/OsmAnd/res/values-es/strings.xml index 80a140d695..448a1a4214 100644 --- a/OsmAnd/res/values-es/strings.xml +++ b/OsmAnd/res/values-es/strings.xml @@ -2850,7 +2850,7 @@ Anual %1$s / mes %1$.2f %2$s / mes - Ahorra %1$s. + Ahorra %1$s Suscripción actual Renovar mensualmente Renovar trimestralmente diff --git a/OsmAnd/res/values-et/strings.xml b/OsmAnd/res/values-et/strings.xml index 6791a51366..83b9a9ec24 100644 --- a/OsmAnd/res/values-et/strings.xml +++ b/OsmAnd/res/values-et/strings.xml @@ -558,7 +558,7 @@ Igal aastal %1$s / kuu %1$.2f %2$s / kuu - Salvesta %1$s. + Salvesta %1$s Praegune tellimus Uueneb igakuiselt Uueneb kord kvartalis diff --git a/OsmAnd/res/values-gl/strings.xml b/OsmAnd/res/values-gl/strings.xml index f04476fd63..0e85997e43 100644 --- a/OsmAnd/res/values-gl/strings.xml +++ b/OsmAnd/res/values-gl/strings.xml @@ -2914,7 +2914,7 @@ Lon %2$s Anual %1$s / mes %1$.2f %2$s / mes - Aforra un %1$s. + Aforra un %1$s Subscrición actual Renovación mensual Renovación trimestral diff --git a/OsmAnd/res/values-he/strings.xml b/OsmAnd/res/values-he/strings.xml index 6b4ddab4f7..741d2b43b0 100644 --- a/OsmAnd/res/values-he/strings.xml +++ b/OsmAnd/res/values-he/strings.xml @@ -2850,7 +2850,7 @@ שנתית %1$s לחודש %1$.2f %2$s לחודש - חיסכון של %1$s. + חיסכון של %1$s המינוי הנוכחי מתחדש חודשית מתחדש רבעונית diff --git a/OsmAnd/res/values-id/strings.xml b/OsmAnd/res/values-id/strings.xml index 5dc6196eff..941b4b3137 100644 --- a/OsmAnd/res/values-id/strings.xml +++ b/OsmAnd/res/values-id/strings.xml @@ -708,7 +708,7 @@ Tahunan %1$s / bulan %1$.2f %2$s / bulan - Hemat %1$s. + Hemat %1$s Langganan saat ini Perpanjang tiap bulan Perpanjang tiap 4 bulan diff --git a/OsmAnd/res/values-is/strings.xml b/OsmAnd/res/values-is/strings.xml index 22116be1f8..80b0850a41 100644 --- a/OsmAnd/res/values-is/strings.xml +++ b/OsmAnd/res/values-is/strings.xml @@ -2864,7 +2864,7 @@ Stendur fyrir svæði: %1$s x %2$s Árlega %1$s / mánuði %1$.2f %2$s / mánuði - Sparaðu %1$s. + Sparaðu %1$s Núverandi áskrift Endurnýjast mánaðarlega Endurnýjast ársfjórðungslega diff --git a/OsmAnd/res/values-it/strings.xml b/OsmAnd/res/values-it/strings.xml index 0daff2361b..7da19dd5a9 100644 --- a/OsmAnd/res/values-it/strings.xml +++ b/OsmAnd/res/values-it/strings.xml @@ -2852,7 +2852,7 @@ Rappresenta l\'area: %1$s x %2$s Annualmente %1$s / mese %1$.2f %2$s / mese - Risparmia %1$s. + Risparmia %1$s Attuale sottoscrizione Abbonamento mensile Rinnovo trimestrale diff --git a/OsmAnd/res/values-ka/strings.xml b/OsmAnd/res/values-ka/strings.xml index 5c83ad4fb1..7458713fa9 100644 --- a/OsmAnd/res/values-ka/strings.xml +++ b/OsmAnd/res/values-ka/strings.xml @@ -1185,7 +1185,7 @@ წელიწადში ერთხელ გადახდა %1$s თვეში %1$.2f %2$s თვეში - დაზოგეთ %1$s ! + დაზოგეთ %1$s თქვენი მიმდინარე გამოწერა თვიური განახლება წლიური განახლება diff --git a/OsmAnd/res/values-lt/strings.xml b/OsmAnd/res/values-lt/strings.xml index 57dafaef09..a8f4eee382 100644 --- a/OsmAnd/res/values-lt/strings.xml +++ b/OsmAnd/res/values-lt/strings.xml @@ -2555,7 +2555,7 @@ Tai yra puikus būdas paremti OsmAnd ir OSM, jei jie jums patinka. Kartą per metus %1$s / mėnuo %1$.2f %2$s / mėnuo - Sutaupyk %1$s! + Sutaupyk %1$s %1$.2f %2$s Pirmiausiai parinkite miestą Vengti tramvajų diff --git a/OsmAnd/res/values-lv/strings.xml b/OsmAnd/res/values-lv/strings.xml index 670dc847a9..2ee47646cc 100644 --- a/OsmAnd/res/values-lv/strings.xml +++ b/OsmAnd/res/values-lv/strings.xml @@ -2652,7 +2652,7 @@ No Afganistānas līdz Zimbabvei, no Austrālijas līdz ASV, Argentīna, Brazīl Ikgadēja %1$s / mēnesī %1$.2f %2$s / mēnesī - Ietaupiet %1$s. + Ietaupiet %1$s Patreizējais abonoments Atjaunojas katru mēnesi Atjaunojas katru ceturksni diff --git a/OsmAnd/res/values-ml/strings.xml b/OsmAnd/res/values-ml/strings.xml index 14e9ed86b3..5a7b728ea8 100644 --- a/OsmAnd/res/values-ml/strings.xml +++ b/OsmAnd/res/values-ml/strings.xml @@ -1797,7 +1797,7 @@ വര്ഷത്തിലൊരിക്കൽ "പ്റതിമാസം %1$s" "പ്റതിമാസം %1$.2f %2$s " - %1$s ലാഭിക്കുക . + %1$s ലാഭിക്കുക നിലവിലെ സബ്സ്ക്രിപ്ഷൻ മാസത്തിലൊരിക്കൽ ആവര്‍ത്തിക്കുക മൂന്നുമാസത്തിലൊരിക്കൽ ആവര്‍ത്തിക്കുക diff --git a/OsmAnd/res/values-nb/strings.xml b/OsmAnd/res/values-nb/strings.xml index fac215406e..13d0fbde8f 100644 --- a/OsmAnd/res/values-nb/strings.xml +++ b/OsmAnd/res/values-nb/strings.xml @@ -2846,7 +2846,7 @@ Årlig %1$s per måned %1$.2f %2$s per måned - Lagre %1$s. + Lagre %1$s Nåværende abonnement Fornyes månedlig Fornyes kvartalsvis diff --git a/OsmAnd/res/values-nl/strings.xml b/OsmAnd/res/values-nl/strings.xml index 4327f37146..e573b51e5b 100644 --- a/OsmAnd/res/values-nl/strings.xml +++ b/OsmAnd/res/values-nl/strings.xml @@ -2739,7 +2739,7 @@ voor Gebied: %1$s x %2$s Jaarlijks %1$s / maand %1$.2f %2$s / maand - Bespaar %1$s. + Bespaar %1$s "Uw huidige abonnement " Wordt maandelijks verlengd "Wordt per kwartaal verlengd " diff --git a/OsmAnd/res/values-oc/strings.xml b/OsmAnd/res/values-oc/strings.xml index 6df44d7459..646da2f246 100644 --- a/OsmAnd/res/values-oc/strings.xml +++ b/OsmAnd/res/values-oc/strings.xml @@ -184,7 +184,7 @@ Cada an %1$s / mes %1$.2f %2$s / mes - Esparnha %1$s. + Esparnha %1$s Soscripcion actuala Abonament mesadier Abonament trimestriau diff --git a/OsmAnd/res/values-pl/strings.xml b/OsmAnd/res/values-pl/strings.xml index 4a034c7aa7..8c11f2145a 100644 --- a/OsmAnd/res/values-pl/strings.xml +++ b/OsmAnd/res/values-pl/strings.xml @@ -2854,7 +2854,7 @@ Reprezentuje obszar: %1$s x %2$s Raz w roku %1$s / miesiąc %1$.2f %2$s / miesiąc - Oszczędź %1$s. + Oszczędź %1$s Aktualna subskrypcja Odnawia się co miesiąc Odnawia się co kwartał diff --git a/OsmAnd/res/values-pt-rBR/strings.xml b/OsmAnd/res/values-pt-rBR/strings.xml index b2a5399e1e..da11e07acd 100644 --- a/OsmAnd/res/values-pt-rBR/strings.xml +++ b/OsmAnd/res/values-pt-rBR/strings.xml @@ -2829,7 +2829,7 @@ Pôr do Sol: %2$s Anualmente %1$s / mês %1$.2f %2$s / mês - Menos %1$s. + Menos %1$s Assinatura atual Renova mensalmente Renova anualmente diff --git a/OsmAnd/res/values-pt/strings.xml b/OsmAnd/res/values-pt/strings.xml index 3ace6a28db..7b52230870 100644 --- a/OsmAnd/res/values-pt/strings.xml +++ b/OsmAnd/res/values-pt/strings.xml @@ -2182,7 +2182,7 @@ Anualmente %1$s / mês %1$.2f %2$s / mês - Poupe %1$s. + Poupe %1$s Assinatura atual Renova mensalmente Renova trimestralmente diff --git a/OsmAnd/res/values-ro/strings.xml b/OsmAnd/res/values-ro/strings.xml index 67c7894459..3e7d433de9 100644 --- a/OsmAnd/res/values-ro/strings.xml +++ b/OsmAnd/res/values-ro/strings.xml @@ -2238,7 +2238,7 @@ Anual %1$s / lună %1$.2f %2$s / lună - Salvați %1$s. + Salvați %1$s Abonament curent Reînnoire lunară Se reînnoiește trimestrial diff --git a/OsmAnd/res/values-ru/strings.xml b/OsmAnd/res/values-ru/strings.xml index 9dbf3b08ed..3732d2f46e 100644 --- a/OsmAnd/res/values-ru/strings.xml +++ b/OsmAnd/res/values-ru/strings.xml @@ -2883,7 +2883,7 @@ Ежегодно %1$s / месяц %1$.2f %2$s / месяц - Экономия %1$s. + Экономия %1$s Текущая подписка Продлевается ежемесячно Продлевается ежеквартально diff --git a/OsmAnd/res/values-sc/strings.xml b/OsmAnd/res/values-sc/strings.xml index 5120a4ecde..afbf848c77 100644 --- a/OsmAnd/res/values-sc/strings.xml +++ b/OsmAnd/res/values-sc/strings.xml @@ -2856,7 +2856,7 @@ Pro praghere iscrie su còdighe intreu Una borta a s\'annu %1$s / mese %1$.2f %2$s / mese - Rispàrmia %1$s. + Rispàrmia %1$s Abbonamentu atuale Si rinnovat cada mese Si rinnovat cada tres meses diff --git a/OsmAnd/res/values-sk/strings.xml b/OsmAnd/res/values-sk/strings.xml index 42eac3f419..c7034a2a87 100644 --- a/OsmAnd/res/values-sk/strings.xml +++ b/OsmAnd/res/values-sk/strings.xml @@ -2843,7 +2843,7 @@ Zodpovedá oblasti: %1$s x %2$s Ročne %1$s / mesiac %1$.2f %2$s / mesiac - Ušetríte %1$s. + Ušetríte %1$s Aktuálne predplatné Obnovuje sa mesačne Obnovuje sa štvrťročne diff --git a/OsmAnd/res/values-sl/strings.xml b/OsmAnd/res/values-sl/strings.xml index e06ef3099b..78db35b699 100644 --- a/OsmAnd/res/values-sl/strings.xml +++ b/OsmAnd/res/values-sl/strings.xml @@ -2763,7 +2763,7 @@ Koda predstavlja območje: %1$s x %2$s Letno %1$s / mesec %1$.2f %2$s / mesec - Prihranite %1$s! + Prihranite %1$s Trenutno naročen paket Mesečna obnovitev Četrtletna obnovitev diff --git a/OsmAnd/res/values-sr/strings.xml b/OsmAnd/res/values-sr/strings.xml index 2f2a240c0e..1a3340e84b 100644 --- a/OsmAnd/res/values-sr/strings.xml +++ b/OsmAnd/res/values-sr/strings.xml @@ -2856,7 +2856,7 @@ годишње %1$s / месечно %1$.2f %2$s / месечно - Уштедите %1$s. + Уштедите %1$s Тренутна претплата Месечно обнављање Квартално обнављање diff --git a/OsmAnd/res/values-sv/strings.xml b/OsmAnd/res/values-sv/strings.xml index fc8bf50103..20b9ae5977 100644 --- a/OsmAnd/res/values-sv/strings.xml +++ b/OsmAnd/res/values-sv/strings.xml @@ -2725,7 +2725,7 @@ Vänligen tillhandahåll fullständig kod Årligen %1$s / månad %1$.2f %2$s / månad - Spara %1$s. + Spara %1$s Aktuell prenumeration Förnyas varje månad Förnyas kvartalsvis diff --git a/OsmAnd/res/values-ta/strings.xml b/OsmAnd/res/values-ta/strings.xml index 366c656a9f..3b4855713e 100644 --- a/OsmAnd/res/values-ta/strings.xml +++ b/OsmAnd/res/values-ta/strings.xml @@ -266,7 +266,7 @@ பயண பதிவுகள் எல்லைகொடு வரிகளின் செருகி "எல்லைகோடு " - சேமிக்க %1$s! + சேமிக்க %1$s \'%s\' வரைப்படப் புள்ளியை அழிக்க\? பாதசாரி மற்றும் மிதிவண்டி சாலைகள் வேறுபடுவதை இயல்புநிலை பாணியின் மாற்றல். மரபுவழி Mapnik வண்ணங்களைப் பயன்படுத்துகிறது. அடையாளக்குறி diff --git a/OsmAnd/res/values-tr/strings.xml b/OsmAnd/res/values-tr/strings.xml index ee1efe89ed..282e2d2a4a 100644 --- a/OsmAnd/res/values-tr/strings.xml +++ b/OsmAnd/res/values-tr/strings.xml @@ -2910,7 +2910,7 @@ \'%s\' harita işaretleyicisini sil\? Harita işaretleyicisini düzenle Plan ve Fiyatlandırma - %1$s tasarruf edin. + %1$s tasarruf edin Mevcut abonelik Üç ayda bir yeniler %1$.2f %2$s diff --git a/OsmAnd/res/values-uk/strings.xml b/OsmAnd/res/values-uk/strings.xml index 1a4d5018e6..9a015f313c 100644 --- a/OsmAnd/res/values-uk/strings.xml +++ b/OsmAnd/res/values-uk/strings.xml @@ -2850,7 +2850,7 @@ Щорічно %1$s / місяць %1$.2f %2$s / місяць - Заощадьте %1$s. + Заощадьте %1$s Поточна підписка Оновлюється щомісяця Оновлюється щокварталу diff --git a/OsmAnd/res/values-zh-rCN/strings.xml b/OsmAnd/res/values-zh-rCN/strings.xml index 99f6bd51d0..7f0187f5d9 100644 --- a/OsmAnd/res/values-zh-rCN/strings.xml +++ b/OsmAnd/res/values-zh-rCN/strings.xml @@ -2528,7 +2528,7 @@ 年度 %1$s / 每月 %1$.2f %2$s / 每月 - 省下 %1$s。 + 省下 %1$s 当前订阅 在网页浏览器中查看条目。 订阅 diff --git a/OsmAnd/res/values-zh-rTW/strings.xml b/OsmAnd/res/values-zh-rTW/strings.xml index 09886a6345..7a603f48fc 100644 --- a/OsmAnd/res/values-zh-rTW/strings.xml +++ b/OsmAnd/res/values-zh-rTW/strings.xml @@ -2846,7 +2846,7 @@ 每年 %1$s / 月 %1$.2f %2$s / 月 - 節省 %1$s。 + 節省 %1$s 目前的訂閱 每月續訂 每季續訂 diff --git a/OsmAnd/src/net/osmand/plus/chooseplan/ChoosePlanDialogFragment.java b/OsmAnd/src/net/osmand/plus/chooseplan/ChoosePlanDialogFragment.java index 2e220c7faf..ece8599f03 100644 --- a/OsmAnd/src/net/osmand/plus/chooseplan/ChoosePlanDialogFragment.java +++ b/OsmAnd/src/net/osmand/plus/chooseplan/ChoosePlanDialogFragment.java @@ -355,15 +355,19 @@ public abstract class ChoosePlanDialogFragment extends BaseOsmAndDialogFragment osmLiveCardButtonsContainer.removeAllViews(); View lastBtn = null; List visibleSubscriptions = purchaseHelper.getLiveUpdates().getVisibleSubscriptions(); + InAppSubscription subscriptionMaxDiscount = null; + double maxDiscount = 0; boolean anyPurchased = false; for (final InAppSubscription s : visibleSubscriptions) { if (s.isPurchased()) { anyPurchased = true; - break; + } + double discount = s.getDiscountPercent(purchaseHelper.getMonthlyLiveUpdates()); + if (discount > maxDiscount) { + subscriptionMaxDiscount = s; + maxDiscount = discount; } } - InAppSubscription subscriptionMaxDiscount = purchaseHelper.getLiveUpdates() - .getSubscriptionWithMaxDiscount(purchaseHelper.getMonthlyLiveUpdates()); boolean maxDiscountAction = subscriptionMaxDiscount != null && (subscriptionMaxDiscount.getIntroductoryInfo() != null || subscriptionMaxDiscount.isUpgrade()); for (final InAppSubscription s : visibleSubscriptions) { diff --git a/OsmAnd/src/net/osmand/plus/inapp/InAppPurchases.java b/OsmAnd/src/net/osmand/plus/inapp/InAppPurchases.java index cbe1de7b92..5fb2e0baa3 100644 --- a/OsmAnd/src/net/osmand/plus/inapp/InAppPurchases.java +++ b/OsmAnd/src/net/osmand/plus/inapp/InAppPurchases.java @@ -258,20 +258,6 @@ public class InAppPurchases { } return null; } - - @Nullable - public InAppSubscription getSubscriptionWithMaxDiscount(@Nullable InAppSubscription monthlyLiveUpdates) { - double maxDiscount = 0; - InAppSubscription subscriptionWithMaxDiscount = null; - for (InAppSubscription s : getAllSubscriptions()) { - double discount = s.getDiscountPercent(monthlyLiveUpdates); - if (discount > maxDiscount) { - subscriptionWithMaxDiscount = s; - maxDiscount = discount; - } - } - return subscriptionWithMaxDiscount; - } } public static class LiveUpdatesInAppPurchasesFree extends InAppSubscriptionList { @@ -773,7 +759,7 @@ public class InAppPurchases { return discountPercent > 0 ? ctx.getString(R.string.osm_live_payment_discount_descr, discountPercent + "%") : ""; } - int getDiscountPercent(@Nullable InAppSubscription monthlyLiveUpdates) { + public int getDiscountPercent(@Nullable InAppSubscription monthlyLiveUpdates) { double monthlyPriceValue = getMonthlyPriceValue(); if (monthlyLiveUpdates != null) { double regularMonthlyPrice = monthlyLiveUpdates.getPriceValue();