diff --git a/indexer/editable_map_object.cpp b/indexer/editable_map_object.cpp index c12443590f..132fe6f764 100644 --- a/indexer/editable_map_object.cpp +++ b/indexer/editable_map_object.cpp @@ -1,7 +1,6 @@ #include "indexer/classificator.hpp" #include "indexer/cuisines.hpp" #include "indexer/editable_map_object.hpp" -#include "indexer/ftypes_matcher.hpp" #include "base/macros.hpp" #include "base/string_utils.hpp" @@ -13,11 +12,6 @@ namespace osm bool EditableMapObject::IsNameEditable() const { return m_editableProperties.m_name; } bool EditableMapObject::IsAddressEditable() const { return m_editableProperties.m_address; } -bool EditableMapObject::ShouldDisplayAddOrganisationButton() const -{ - return ftypes::IsBuildingChecker::Instance()(m_types); -} - vector EditableMapObject::GetEditableProperties() const { return MetadataToProps(m_editableProperties.m_metadata); diff --git a/indexer/editable_map_object.hpp b/indexer/editable_map_object.hpp index c29fbd834a..5f63cdd994 100644 --- a/indexer/editable_map_object.hpp +++ b/indexer/editable_map_object.hpp @@ -48,7 +48,6 @@ class EditableMapObject : public MapObject public: bool IsNameEditable() const; bool IsAddressEditable() const; - bool ShouldDisplayAddOrganisationButton() const; vector GetEditableProperties() const; // TODO(AlexZ): Remove this method and use GetEditableProperties() in UI. diff --git a/indexer/map_object.cpp b/indexer/map_object.cpp index 17891111f3..927ff1f987 100644 --- a/indexer/map_object.cpp +++ b/indexer/map_object.cpp @@ -4,6 +4,7 @@ #include "indexer/cuisines.hpp" #include "indexer/feature.hpp" #include "indexer/feature_algo.hpp" +#include "indexer/ftypes_matcher.hpp" #include "platform/measurement_utils.hpp" #include "platform/preferred_languages.hpp" @@ -188,5 +189,11 @@ string MapObject::GetBuildingLevels() const } feature::Metadata const & MapObject::GetMetadata() const { return m_metadata; } + bool MapObject::IsPointType() const { return m_geomType == feature::EGeomType::GEOM_POINT; } + +bool MapObject::IsBuilding() const +{ + return ftypes::IsBuildingChecker::Instance()(m_types); +} } // namespace osm diff --git a/indexer/map_object.hpp b/indexer/map_object.hpp index a97dae8b7c..a26db39d04 100644 --- a/indexer/map_object.hpp +++ b/indexer/map_object.hpp @@ -95,6 +95,8 @@ public: feature::Metadata const & GetMetadata() const; bool IsPointType() const; + /// @returns true if object is of building type. + bool IsBuilding() const; protected: FeatureID m_featureID;