diff --git a/android/res/values-cs/strings.xml b/android/res/values-cs/strings.xml index 4968a967bb..823979e3da 100644 --- a/android/res/values-cs/strings.xml +++ b/android/res/values-cs/strings.xml @@ -103,13 +103,13 @@ pamětihodnosti - ^přidáno do\nfronty stahování. + ^přidáno do fronty stahování. - Stahuji^ (^%) + Stahuji^^% Stáhnout^ - Stahování^\nselhalo + Stahování^selhalo Opakuj akci O aplikaci MapsWithMe diff --git a/android/res/values-de/strings.xml b/android/res/values-de/strings.xml index 811514d570..c6f2f8cc22 100644 --- a/android/res/values-de/strings.xml +++ b/android/res/values-de/strings.xml @@ -107,13 +107,13 @@ Sehenswürdigkeit - ^wird zur\nDownload-Warteschleife hinzugefügt + ^wird zur Download-Warteschleife hinzugefügt - Wird heruntergeladen^ (^%) + Wird heruntergeladen^^% Herunterladen^ - Download^\nfehlgeschlagen + Download^fehlgeschlagen Nochmals versuchen Über MapsWithMe diff --git a/android/res/values-es/strings.xml b/android/res/values-es/strings.xml index 4ad80795c0..06a892b054 100644 --- a/android/res/values-es/strings.xml +++ b/android/res/values-es/strings.xml @@ -103,13 +103,13 @@ turismo - ^añadido a la cola\nde descarga + ^añadido a la cola de descarga - Descargando^ (^%) + Descargando^^% Descargar^ - Error durante la descarga\n^ + Error durante la descarga^ Intentarla otra vez Sobre MapsWithMe diff --git a/android/res/values-fr/strings.xml b/android/res/values-fr/strings.xml index b9325f9ec6..93c74d62de 100644 --- a/android/res/values-fr/strings.xml +++ b/android/res/values-fr/strings.xml @@ -99,13 +99,13 @@ curiosités - ^ajouté à son tour\nde télécharger + ^ajouté à son tour de télécharger - Téléchargement en cours^ (^%) + Téléchargement en cours^^% Charger^ - Erreur de téléchargement\n^ + Erreur de téléchargement^ Essayez encore une fois Au sujet des cartes diff --git a/android/res/values-ja/strings.xml b/android/res/values-ja/strings.xml index f3b2a21ba8..fd6fcbf829 100644 --- a/android/res/values-ja/strings.xml +++ b/android/res/values-ja/strings.xml @@ -105,13 +105,13 @@ 観光 - ^をダウンロードキューに\n追加しました + ^をダウンロードキューに追加しました - ダウンロード中^ (^%) + ダウンロード中^^% ダウンロード^ - ダウンロードに失敗しました\n^ + ダウンロードに失敗しました^ 再実行 情報 diff --git a/android/res/values-ko/strings.xml b/android/res/values-ko/strings.xml index 84069c798b..ccdf71c883 100644 --- a/android/res/values-ko/strings.xml +++ b/android/res/values-ko/strings.xml @@ -101,13 +101,13 @@ 관광 - ^는 다운로드 대기열에\n추가됩니다. + ^는 다운로드 대기열에추가됩니다. - 다운로드 중^ (^%) + 다운로드 중^^% 다운로드^ - 다운로드에 실패하였습니다\n^ + 다운로드에 실패하였습니다^ 다시 시도 소개 diff --git a/android/res/values-nl/strings.xml b/android/res/values-nl/strings.xml index e093eaa324..448ec39a74 100644 --- a/android/res/values-nl/strings.xml +++ b/android/res/values-nl/strings.xml @@ -111,13 +111,13 @@ toerisme - ^is toegevoegd aan de\ndownload wachtrij + ^is toegevoegd aan de download wachtrij - aan het downloaden^ (^%) + aan het downloaden^^% Download^ - Downloaden^\nis niet gelukt + Downloaden^is niet gelukt Probeer opnieuw Over MapsWithMe diff --git a/android/res/values-ru/strings.xml b/android/res/values-ru/strings.xml index f289ba91d2..6e07bf5154 100644 --- a/android/res/values-ru/strings.xml +++ b/android/res/values-ru/strings.xml @@ -111,13 +111,13 @@ достопримечательность - ^добавлено в очередь\nзагрузки. + ^добавлено в очередь загрузки. - Загружается^ (^%) + Загружается^^% Загрузить^ - Ошибка загрузки\n^ + Ошибка загрузки^ Попробуйте еще раз О программе diff --git a/android/res/values-uk/strings.xml b/android/res/values-uk/strings.xml index fc1b1a528a..0749e25627 100644 --- a/android/res/values-uk/strings.xml +++ b/android/res/values-uk/strings.xml @@ -99,13 +99,13 @@ Показати країну на карті - ^добавлено в чергу\nзавантаження. + ^добавлено в чергу завантаження. - Завантажується^ (^%) + Завантажується^^% Завантажити^ - Помилка завантаження^. + Помилка завантаження^ Спробуйте ще раз Про програму diff --git a/android/res/values/strings.xml b/android/res/values/strings.xml index b4fbc22c27..7337636850 100644 --- a/android/res/values/strings.xml +++ b/android/res/values/strings.xml @@ -114,13 +114,13 @@ sights - ^is added to the\ndownloading queue. + ^is added to the downloading queue. - Downloading^ (^%) + Downloading^^% Download^ - Downloading^\nhas failed + Downloading^has failed Try Again MapsWithMe diff --git a/iphone/Maps/de.lproj/Localizable.strings b/iphone/Maps/de.lproj/Localizable.strings index d476e9ff7e..f304fbc30c 100644 --- a/iphone/Maps/de.lproj/Localizable.strings +++ b/iphone/Maps/de.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "Sehenswürdigkeit"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^wird zur\nDownload-Warteschleife hinzugefügt"; +"country_status_added_to_queue" = "^wird zur Download-Warteschleife hinzugefügt"; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "Wird heruntergeladen^ (^%)"; +"country_status_downloading" = "Wird heruntergeladen^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "Herunterladen^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "Download^\nfehlgeschlagen"; +"country_status_download_failed" = "Download^fehlgeschlagen"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "Nochmals versuchen"; diff --git a/iphone/Maps/en.lproj/Localizable.strings b/iphone/Maps/en.lproj/Localizable.strings index 66e8077913..622b834553 100644 --- a/iphone/Maps/en.lproj/Localizable.strings +++ b/iphone/Maps/en.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "sights"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^is added to the\ndownloading queue."; +"country_status_added_to_queue" = "^is added to the downloading queue."; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "Downloading^ (^%)"; +"country_status_downloading" = "Downloading^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "Download^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "Downloading^\nhas failed"; +"country_status_download_failed" = "Downloading^has failed"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "Try Again"; diff --git a/iphone/Maps/es.lproj/Localizable.strings b/iphone/Maps/es.lproj/Localizable.strings index 13c0bb50ba..c6aa922d73 100644 --- a/iphone/Maps/es.lproj/Localizable.strings +++ b/iphone/Maps/es.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "turismo"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^añadido a la cola\nde descarga"; +"country_status_added_to_queue" = "^añadido a la cola de descarga"; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "Descargando^ (^%)"; +"country_status_downloading" = "Descargando^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "Descargar^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "Error durante la descarga\n^"; +"country_status_download_failed" = "Error durante la descarga^"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "Intentarla otra vez"; diff --git a/iphone/Maps/fr.lproj/Localizable.strings b/iphone/Maps/fr.lproj/Localizable.strings index 2f41fad336..269c8ac21d 100644 --- a/iphone/Maps/fr.lproj/Localizable.strings +++ b/iphone/Maps/fr.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "curiosités"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^ajouté à son tour\nde télécharger"; +"country_status_added_to_queue" = "^ajouté à son tour de télécharger"; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "Téléchargement en cours^ (^%)"; +"country_status_downloading" = "Téléchargement en cours^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "Charger^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "Erreur de téléchargement\n^"; +"country_status_download_failed" = "Erreur de téléchargement^"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "Essayez encore une fois"; diff --git a/iphone/Maps/it.lproj/Localizable.strings b/iphone/Maps/it.lproj/Localizable.strings index 2676c88e2e..a2962deddd 100644 --- a/iphone/Maps/it.lproj/Localizable.strings +++ b/iphone/Maps/it.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "turistico"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^is added to the\ndownloading queue."; +"country_status_added_to_queue" = "^is added to the downloading queue."; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "Downloading^ (^%)"; +"country_status_downloading" = "Downloading^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "Download^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "Downloading^\nhas failed"; +"country_status_download_failed" = "Downloading^has failed"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "Try Again"; diff --git a/iphone/Maps/ja.lproj/Localizable.strings b/iphone/Maps/ja.lproj/Localizable.strings index 6c470ca6a9..7b3dd3ac4d 100644 --- a/iphone/Maps/ja.lproj/Localizable.strings +++ b/iphone/Maps/ja.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "観光"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^をダウンロードキューに\n追加しました"; +"country_status_added_to_queue" = "^をダウンロードキューに追加しました"; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "ダウンロード中^ (^%)"; +"country_status_downloading" = "ダウンロード中^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "ダウンロード^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "ダウンロードに失敗しました\n^"; +"country_status_download_failed" = "ダウンロードに失敗しました^"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "再実行"; diff --git a/iphone/Maps/ko.lproj/Localizable.strings b/iphone/Maps/ko.lproj/Localizable.strings index 8f3e215533..6ed535021f 100644 --- a/iphone/Maps/ko.lproj/Localizable.strings +++ b/iphone/Maps/ko.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "관광"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^는 다운로드 대기열에\n추가됩니다."; +"country_status_added_to_queue" = "^는 다운로드 대기열에추가됩니다."; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "다운로드 중^ (^%)"; +"country_status_downloading" = "다운로드 중^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "다운로드^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "다운로드에 실패하였습니다\n^"; +"country_status_download_failed" = "다운로드에 실패하였습니다^"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "다시 시도"; diff --git a/iphone/Maps/nl.lproj/Localizable.strings b/iphone/Maps/nl.lproj/Localizable.strings index 1138697a18..e32f122560 100644 --- a/iphone/Maps/nl.lproj/Localizable.strings +++ b/iphone/Maps/nl.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "toerisme"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^is toegevoegd aan de\ndownload wachtrij"; +"country_status_added_to_queue" = "^is toegevoegd aan de download wachtrij"; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "aan het downloaden^ (^%)"; +"country_status_downloading" = "aan het downloaden^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "Download^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "Downloaden^\nis niet gelukt"; +"country_status_download_failed" = "Downloaden^is niet gelukt"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "Probeer opnieuw"; diff --git a/iphone/Maps/ru.lproj/Localizable.strings b/iphone/Maps/ru.lproj/Localizable.strings index 5d3c21bbae..af24393669 100644 --- a/iphone/Maps/ru.lproj/Localizable.strings +++ b/iphone/Maps/ru.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "достопримечательность"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^добавлено в очередь\nзагрузки."; +"country_status_added_to_queue" = "^добавлено в очередь загрузки."; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "Загружается^ (^%)"; +"country_status_downloading" = "Загружается^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "Загрузить^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "Ошибка загрузки\n^"; +"country_status_download_failed" = "Ошибка загрузки^"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "Попробуйте еще раз"; diff --git a/iphone/Maps/uk.lproj/Localizable.strings b/iphone/Maps/uk.lproj/Localizable.strings index 8cfb0860e6..213596a46f 100644 --- a/iphone/Maps/uk.lproj/Localizable.strings +++ b/iphone/Maps/uk.lproj/Localizable.strings @@ -172,16 +172,16 @@ "tourism" = "sights"; /* Message to display at the center of the screen when the country is added to the downloading queue */ -"country_status_added_to_queue" = "^добавлено в чергу\nзавантаження."; +"country_status_added_to_queue" = "^добавлено в чергу завантаження."; /* Message to display at the center of the screen when the country is downloading */ -"country_status_downloading" = "Завантажується^ (^%)"; +"country_status_downloading" = "Завантажується^^%"; /* Button text for the button at the center of the screen when the country is not downloaded */ "country_status_download" = "Завантажити^"; /* Message to display at the center of the screen when the country download has failed */ -"country_status_download_failed" = "Помилка завантаження^."; +"country_status_download_failed" = "Помилка завантаження^"; /* Button text for the button under the country_status_download_failed message */ "try_again" = "Спробуйте ще раз"; diff --git a/map/country_status_display.cpp b/map/country_status_display.cpp index d0c6c5365a..e64b36fa0f 100644 --- a/map/country_status_display.cpp +++ b/map/country_status_display.cpp @@ -23,18 +23,25 @@ string const CountryStatusDisplay::displayName() const template void CountryStatusDisplay::SetStatusMessage(string const & msgID, T1 const * t1, T2 const * t2) { - m_statusMsg->setIsVisible(true); - setIsVisible(m_statusMsg->isVisible() || m_downloadButton->isVisible()); - string msg = m_controller->GetStringsBundle()->GetString(msgID); if (t1) { if (t2) msg = strings::Format(msg, *t1, *t2); else + { msg = strings::Format(msg, *t1); + + size_t const count = msg.size(); + if (count > 0) + { + if (msg[count-1] == '\n') + msg.erase(count-1, 1); + } + } } + m_statusMsg->setIsVisible(true); m_statusMsg->setText(msg); } @@ -45,42 +52,24 @@ void CountryStatusDisplay::cache() setIsVisible(false); setIsDirtyRect(true); - string dn = displayName(); - strings::UniString udn(strings::MakeUniString(dn)); - - string prefixedName; - string postfixedName; - - if (udn.size() > 13) - { - if (strings::MakeUniString(m_mapName).size() > 13) - { - dn = m_mapName; - if (!m_mapGroupName.empty()) - dn = dn + "\n"+ "(" + m_mapGroupName + ")"; - } - - prefixedName = "\n" + dn; - postfixedName = dn + "\n"; - } - else - { - prefixedName = " " + dn; - postfixedName = dn + " "; - } + string const dn = displayName(); if (m_countryIdx != storage::TIndex()) { switch (m_countryStatus) { case storage::EInQueue: - SetStatusMessage("country_status_added_to_queue", &postfixedName); + { + string const s = dn + "\n"; + SetStatusMessage("country_status_added_to_queue", &s); break; + } case storage::EDownloading: { - int percent = m_countryProgress.first * 100 / m_countryProgress.second; - SetStatusMessage("country_status_downloading", &prefixedName, &percent); + int const percent = m_countryProgress.first * 100 / m_countryProgress.second; + string const s = "\n" + dn + "\n"; + SetStatusMessage("country_status_downloading", &s, &percent); break; } @@ -91,18 +80,21 @@ void CountryStatusDisplay::cache() { m_downloadButton->setIsVisible(true); string const msg = m_controller->GetStringsBundle()->GetString("country_status_download"); - m_downloadButton->setText(strings::Format(msg, prefixedName)); + m_downloadButton->setText(strings::Format(msg, "\n" + dn)); } break; case storage::EDownloadFailed: + { m_downloadButton->setIsVisible(true); m_downloadButton->setText(m_controller->GetStringsBundle()->GetString("try_again")); - SetStatusMessage("country_status_download_failed", &prefixedName); + string const s = "\n" + dn + "\n"; + SetStatusMessage("country_status_download_failed", &s); setPivot(pivot()); break; + } default: return; @@ -111,7 +103,8 @@ void CountryStatusDisplay::cache() setIsVisible(m_statusMsg->isVisible() || m_downloadButton->isVisible()); - // element bound rect is possibly changed + // Element bound rect is possibly changed, + // however it's called in the beginning of the function. setIsDirtyRect(true); } diff --git a/map/framework.cpp b/map/framework.cpp index 71d6acb517..7c5ec15cb3 100644 --- a/map/framework.cpp +++ b/map/framework.cpp @@ -188,12 +188,12 @@ Framework::Framework() m_benchmarkEngine = new BenchmarkEngine(this); // Init strings bundle. - m_stringsBundle.SetDefaultString("country_status_added_to_queue", "^is added to the\ndownloading queue."); - m_stringsBundle.SetDefaultString("country_status_downloading", "Downloading^(^%)"); + m_stringsBundle.SetDefaultString("country_status_added_to_queue", "^is added to the downloading queue"); + m_stringsBundle.SetDefaultString("country_status_downloading", "Downloading^^%"); m_stringsBundle.SetDefaultString("country_status_download", "Download^"); - m_stringsBundle.SetDefaultString("country_status_download_failed", "Downloading^\nhas failed"); + m_stringsBundle.SetDefaultString("country_status_download_failed", "Downloading^has failed"); m_stringsBundle.SetDefaultString("try_again", "Try Again"); - m_stringsBundle.SetDefaultString("not_enough_free_space_on_sdcard", "Not enough space\nfor downloading"); + m_stringsBundle.SetDefaultString("not_enough_free_space_on_sdcard", "Not enough space for downloading"); m_animController.reset(new anim::Controller()); diff --git a/strings.txt b/strings.txt index e176858480..9bfd9d7313 100644 --- a/strings.txt +++ b/strings.txt @@ -628,31 +628,31 @@ cs = pamětihodnosti nl = toerisme [country_status_added_to_queue] - en = ^is added to the\ndownloading queue. + en = ^is added to the downloading queue. comment = Message to display at the center of the screen when the country is added to the downloading queue - de = ^wird zur\nDownload-Warteschleife hinzugefügt - es = ^añadido a la cola\nde descarga - fr = ^ajouté à son tour\nde télécharger - ja = ^をダウンロードキューに\n追加しました - ko = ^는 다운로드 대기열에\n추가됩니다. - ru = ^добавлено в очередь\nзагрузки. - cs = ^přidáno do\nfronty stahování. - uk = ^добавлено в чергу\nзавантаження. - nl = ^is toegevoegd aan de\ndownload wachtrij + de = ^wird zur Download-Warteschleife hinzugefügt + es = ^añadido a la cola de descarga + fr = ^ajouté à son tour de télécharger + ja = ^をダウンロードキューに追加しました + ko = ^는 다운로드 대기열에추가됩니다. + ru = ^добавлено в очередь загрузки. + cs = ^přidáno do fronty stahování. + uk = ^добавлено в чергу завантаження. + nl = ^is toegevoegd aan de download wachtrij [country_status_downloading] - en = Downloading^ (^%) + en = Downloading^^% comment = Message to display at the center of the screen when the country is downloading - de = Wird heruntergeladen^ (^%) - es = Descargando^ (^%) - fr = Téléchargement en cours^ (^%) - ja = ダウンロード中^ (^%) - ko = 다운로드 중^ (^%) - ru = Загружается^ (^%) - cs = Stahování^ (^%) - ru = Загружается^ (^%) - uk = Завантажується^ (^%) - cs = Stahuji^ (^%) - nl = aan het downloaden^ (^%) + de = Wird heruntergeladen^^% + es = Descargando^^% + fr = Téléchargement en cours^^% + ja = ダウンロード中^^% + ko = 다운로드 중^^% + ru = Загружается^^% + cs = Stahování^^% + ru = Загружается^^% + uk = Завантажується^^% + cs = Stahuji^^% + nl = aan het downloaden^^% [country_status_download] en = Download^ comment = Button text for the button at the center of the screen when the country is not downloaded @@ -666,17 +666,17 @@ cs = Stáhnout^ nl = Download^ [country_status_download_failed] - en = Downloading^\nhas failed + en = Downloading^has failed comment = Message to display at the center of the screen when the country download has failed - de = Download^\nfehlgeschlagen - es = Error durante la descarga\n^ - fr = Erreur de téléchargement\n^ - ja = ダウンロードに失敗しました\n^ - ko = 다운로드에 실패하였습니다\n^ - ru = Ошибка загрузки\n^ - uk = Помилка завантаження^. - cs = Stahování^\nselhalo - nl = Downloaden^\nis niet gelukt + de = Download^fehlgeschlagen + es = Error durante la descarga^ + fr = Erreur de téléchargement^ + ja = ダウンロードに失敗しました^ + ko = 다운로드에 실패하였습니다^ + ru = Ошибка загрузки^ + uk = Помилка завантаження^ + cs = Stahování^selhalo + nl = Downloaden^is niet gelukt [try_again] en = Try Again comment = Button text for the button under the country_status_download_failed message