mirror of
https://codeberg.org/comaps/comaps
synced 2026-01-05 20:23:48 +00:00
[android] Add function to get all android system languages
Signed-off-by: gekeleda <git@davidgekeler.eu>
This commit is contained in:
@@ -24,7 +24,7 @@
|
||||
#include <cstdlib>
|
||||
#elif defined(OMIM_OS_ANDROID)
|
||||
/// Body for this function is inside android/sdk/src/main/cpp sources
|
||||
std::string GetAndroidSystemLanguage();
|
||||
std::vector<std::string> GetAndroidSystemLanguages();
|
||||
#else
|
||||
#error "Define language preferences for your platform"
|
||||
#endif
|
||||
@@ -514,7 +514,9 @@ struct SystemLanguages
|
||||
}
|
||||
|
||||
#elif defined(OMIM_OS_ANDROID)
|
||||
m_langs.push_back(GetAndroidSystemLanguage());
|
||||
std::vector<std::string> system_langs = GetAndroidSystemLanguages();
|
||||
for (auto const & lang : system_langs)
|
||||
m_langs.push_back(lang);
|
||||
#else
|
||||
#error "Define language preferences for your platform"
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user