diff --git a/map/framework.cpp b/map/framework.cpp index 698dde13fc..554bd4c797 100644 --- a/map/framework.cpp +++ b/map/framework.cpp @@ -1198,7 +1198,6 @@ void Framework::ShowSearchResult(search::Result const & res) break; case Result::RESULT_LATLON: - case Result::RESULT_ADDRESS: FillPointInfo(res.GetFeatureCenter(), res.GetString(), info); scale = scales::GetUpperComfortScale(); break; diff --git a/search/result.cpp b/search/result.cpp index 0232fd2fb9..a18a107d6d 100644 --- a/search/result.cpp +++ b/search/result.cpp @@ -71,7 +71,7 @@ Result::ResultType Result::GetResultType() const if (idValid) return RESULT_FEATURE; else - return (m_type.empty() ? RESULT_LATLON : RESULT_ADDRESS); + return RESULT_LATLON; } bool Result::IsSuggest() const @@ -116,24 +116,19 @@ bool Result::IsEqualFeature(Result const & r) const if (type != r.GetResultType()) return false; - if (type == RESULT_ADDRESS) - return (PointDistance(m_center, r.m_center) < 50.0); - else - { - ASSERT_EQUAL(type, Result::RESULT_FEATURE, ()); + ASSERT_EQUAL(type, Result::RESULT_FEATURE, ()); - ASSERT(m_id.IsValid() && r.m_id.IsValid(), ()); - if (m_id == r.m_id) - return true; + ASSERT(m_id.IsValid() && r.m_id.IsValid(), ()); + if (m_id == r.m_id) + return true; - // This function is used to filter duplicate results in cases: - // - emitted World.mwm and Country.mwm - // - after additional search in all mwm - // so it's suitable here to test for 500m - return (m_str == r.m_str && m_region == r.m_region && - m_featureType == r.m_featureType && - PointDistance(m_center, r.m_center) < 500.0); - } + // This function is used to filter duplicate results in cases: + // - emitted World.mwm and Country.mwm + // - after additional search in all mwm + // so it's suitable here to test for 500m + return (m_str == r.m_str && m_region == r.m_region && + m_featureType == r.m_featureType && + PointDistance(m_center, r.m_center) < 500.0); } void Result::AddHighlightRange(pair const & range) @@ -173,7 +168,6 @@ bool Results::AddResult(Result && res) switch (r.GetResultType()) { case Result::RESULT_FEATURE: - case Result::RESULT_ADDRESS: return true; default: return false; diff --git a/search/result.hpp b/search/result.hpp index 3d3f226066..52524c05ec 100644 --- a/search/result.hpp +++ b/search/result.hpp @@ -24,7 +24,6 @@ public: { RESULT_FEATURE, RESULT_LATLON, - RESULT_ADDRESS, RESULT_SUGGEST_PURE, RESULT_SUGGEST_FROM_FEATURE };