diff options
author | vng <viktor.govako@gmail.com> | 2012-12-17 14:50:17 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:48:01 +0300 |
commit | 362a283c933a30ceb86ce090759d499bd9afebcc (patch) | |
tree | fa827919a5e2b6ef4619195e2a6e63776637525e /map | |
parent | 350802ddc90ce86a9e069982e94209d3ec051b6a (diff) |
[android] Replace country name with country index in downloading routine.
Diffstat (limited to 'map')
-rw-r--r-- | map/framework.cpp | 5 | ||||
-rw-r--r-- | map/framework.hpp | 7 |
2 files changed, 6 insertions, 6 deletions
diff --git a/map/framework.cpp b/map/framework.cpp index 7edaf2b81a..b07715efef 100644 --- a/map/framework.cpp +++ b/map/framework.cpp @@ -1346,10 +1346,9 @@ void Framework::DeleteOldMaps() } */ -string Framework::GetCountryCodeByPosition(double lat, double lon) const +string Framework::GetCountryCode(m2::PointD const & pt) const { - return GetSearchEngine()->GetCountryCode(m2::PointD( - MercatorBounds::LonToX(lon), MercatorBounds::LatToY(lat))); + return GetSearchEngine()->GetCountryCode(pt); } gui::Controller * Framework::GetGuiController() const diff --git a/map/framework.hpp b/map/framework.hpp index 1d3fc661d7..23e23be2f8 100644 --- a/map/framework.hpp +++ b/map/framework.hpp @@ -271,15 +271,16 @@ public: double lat, double lon, double north, string & distance, double & azimut); -private: + //@{ storage::TIndex GetCountryIndex(m2::PointD const & pt) const; -public: + string GetCountryName(m2::PointD const & pt) const; /// @param[in] id Country file name without an extension. string GetCountryName(string const & id) const; /// @return country code in ISO 3166-1 alpha-2 format (two small letters) or empty string - string GetCountryCodeByPosition(double lat, double lon) const; + string GetCountryCode(m2::PointD const & pt) const; + //@} void SetMaxWorldRect(); |