Remove localization

This commit is contained in:
LaGrunge 2019-10-09 15:06:46 +03:00
parent 1b9dae3b38
commit 750aadbc9a
5 changed files with 1 additions and 52 deletions

View file

@ -4,7 +4,6 @@
#include "indexer/feature_algo.hpp"
#include "indexer/ftypes_matcher.hpp"
#include "platform/localization.hpp"
#include "platform/measurement_utils.hpp"
#include "base/logging.hpp"
@ -117,7 +116,7 @@ string MapObject::GetLocalizedType() const
feature::TypesHolder copy(m_types);
copy.SortBySpec();
return platform::GetLocalizedTypeName(classif().GetReadableObjectName(*copy.begin()));
return classif().GetReadableObjectName(*copy.begin());
}
vector<osm::Props> MapObject::AvailableProperties() const

View file

@ -13,8 +13,6 @@ set(
local_country_file.hpp
local_country_file_utils.cpp
local_country_file_utils.hpp
localization.hpp
localization_dummy.cpp
measurement_utils.cpp
measurement_utils.hpp
mwm_version.cpp

View file

@ -1,10 +0,0 @@
#pragma once
#include <string>
namespace platform
{
extern std::string GetLocalizedTypeName(std::string const & type);
extern std::string GetLocalizedBrandName(std::string const & brand);
extern std::string GetLocalizedString(std::string const & key);
} // namespace platform

View file

@ -1,28 +0,0 @@
#include "platform/localization.hpp"
#include <algorithm>
#import <Foundation/Foundation.h>
namespace platform
{
std::string GetLocalizedTypeName(std::string const & type)
{
auto key = "type." + type;
std::replace(key.begin(), key.end(), '-', '.');
std::replace(key.begin(), key.end(), ':', '_');
return [NSLocalizedString(@(key.c_str()), @"") UTF8String];
}
std::string GetLocalizedBrandName(std::string const & brand)
{
auto const key = "brand." + brand;
return [NSLocalizedString(@(key.c_str()), @"") UTF8String];
}
std::string GetLocalizedString(std::string const & key)
{
return [NSLocalizedString(@(key.c_str()), @"") UTF8String];
}
} // namespace platform

View file

@ -1,10 +0,0 @@
#include "platform/localization.hpp"
namespace platform
{
std::string GetLocalizedTypeName(std::string const & type) { return type; }
std::string GetLocalizedBrandName(std::string const & brand) { return brand; }
std::string GetLocalizedString(std::string const & key) { return key; }
} // namespace platform