forked from organicmaps/organicmaps
[search] Return POI type before building type to recognize POIs with address.
This commit is contained in:
parent
36be8bd535
commit
b4f30af73f
1 changed files with 4 additions and 3 deletions
|
@ -85,6 +85,10 @@ Model::Type Model::GetType(FeatureType const & feature) const
|
|||
static auto const & localityChecker = IsLocalityChecker::Instance();
|
||||
static auto const & poiChecker = IsPoiChecker::Instance();
|
||||
|
||||
// Check whether object is POI first to mark POIs with address tags as POI.
|
||||
if (poiChecker(feature))
|
||||
return TYPE_POI;
|
||||
|
||||
if (buildingChecker(feature))
|
||||
return TYPE_BUILDING;
|
||||
|
||||
|
@ -106,9 +110,6 @@ Model::Type Model::GetType(FeatureType const & feature) const
|
|||
}
|
||||
}
|
||||
|
||||
if (poiChecker(feature))
|
||||
return TYPE_POI;
|
||||
|
||||
return TYPE_UNCLASSIFIED;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue