Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvng <viktor.govako@gmail.com>2014-11-05 02:56:55 +0300
committerAlex Zolotarev <alex@maps.me>2015-09-23 02:32:16 +0300
commitdfb1644047eee71484007806b53457ed4f4f03ff (patch)
tree4a4b9df86b67ab8f591238feeff8f285a7ae864c /indexer/feature_covering.cpp
parent39818e3e081419e1307017bf90acc9a886eb64b8 (diff)
Minor refaсtoring: removed CoordPointT typedef to avoid disambiguate.
Diffstat (limited to 'indexer/feature_covering.cpp')
-rw-r--r--indexer/feature_covering.cpp19
1 files changed, 7 insertions, 12 deletions
diff --git a/indexer/feature_covering.cpp b/indexer/feature_covering.cpp
index dbdba94730..7aa3fb4307 100644
--- a/indexer/feature_covering.cpp
+++ b/indexer/feature_covering.cpp
@@ -6,13 +6,9 @@
#include "../geometry/covering_utils.hpp"
-#include "../base/base.hpp"
-#include "../base/stl_add.hpp"
-
-#include "../std/algorithm.hpp"
-#include "../std/bind.hpp"
#include "../std/vector.hpp"
+
namespace
{
@@ -98,23 +94,22 @@ public:
typedef CellIdConverter<MercatorBounds, RectId> CellIdConverterType;
- m2::PointD ConvertPoint(double x, double y)
+ m2::PointD ConvertPoint(m2::PointD const & p)
{
- m2::PointD pt(CellIdConverterType::XToCellIdX(x), CellIdConverterType::YToCellIdY(y));
+ m2::PointD const pt(CellIdConverterType::XToCellIdX(p.x),
+ CellIdConverterType::YToCellIdY(p.y));
m_rect.Add(pt);
return pt;
}
- void operator() (pair<double, double> const & pt)
+ void operator() (m2::PointD const & pt)
{
- m_polyline.push_back(ConvertPoint(pt.first, pt.second));
+ m_polyline.push_back(ConvertPoint(pt));
}
void operator() (m2::PointD const & a, m2::PointD const & b, m2::PointD const & c)
{
- m_trg.push_back(Trg(ConvertPoint(a.x, a.y),
- ConvertPoint(b.x, b.y),
- ConvertPoint(c.x, c.y)));
+ m_trg.emplace_back(ConvertPoint(a), ConvertPoint(b), ConvertPoint(c));
}
};