diff options
author | ExMix <rahuba.youri@mapswithme.com> | 2014-09-29 17:36:41 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 02:28:56 +0300 |
commit | 4684878489a7919c31f1627d3b670125242f1b0f (patch) | |
tree | 076885daad9dec510be95eafa8a0bd7431972c3b /map/track.hpp | |
parent | 78bf5cec4076d17ad7bb5366471c251925d64c07 (diff) |
[core] new route track design
Diffstat (limited to 'map/track.hpp')
-rw-r--r-- | map/track.hpp | 25 |
1 files changed, 7 insertions, 18 deletions
diff --git a/map/track.hpp b/map/track.hpp index 3c0b4756d4..d6aceac20f 100644 --- a/map/track.hpp +++ b/map/track.hpp @@ -8,7 +8,6 @@ #include "../std/noncopyable.hpp" - class Navigator; namespace graphics { @@ -16,7 +15,6 @@ namespace graphics class DisplayList; } - class Track : private noncopyable { typedef math::Matrix<double, 3, 3> MatrixT; @@ -29,18 +27,12 @@ public: Track() : m_isVisible(true), m_width(5), m_color(graphics::Color::fromARGB(0xFFFF0000)), - m_isMarked(false), - m_outlineWidth(0), - m_outlineColor(graphics::Color::White()), m_dList(0) {} explicit Track(PolylineD const & polyline) : m_isVisible(true), m_width(5), m_color(graphics::Color::fromARGB(0xFFFF0000)), - m_isMarked(false), - m_outlineWidth(0), - m_outlineColor(graphics::Color::White()), m_polyline(polyline), m_dList(0) { @@ -68,14 +60,13 @@ public: graphics::Color const & GetColor() const { return m_color; } void SetColor(graphics::Color const & color) { m_color = color; } - bool IsMarked() const { return m_isMarked; } - void SetIsMarked(bool isMarked) { m_isMarked = isMarked; } - - float GetOutlineWidth() const { return m_outlineWidth; } - void SetOutlineWidth(float outlineWidth) { m_outlineWidth = outlineWidth; } + struct TrackOutline + { + float m_lineWidth; + graphics::Color m_color; + }; - graphics::Color const & GetOutlineColor() { return m_outlineColor; } - void SetOutlineColor(graphics::Color const & outlineColor) { m_outlineColor = outlineColor; } + void AddOutline(TrackOutline const * outline, int arraySize); string const & GetName() const { return m_name; } void SetName(string const & name) { m_name = name; } @@ -98,9 +89,7 @@ private: float m_width; graphics::Color m_color; - bool m_isMarked; - float m_outlineWidth; - graphics::Color m_outlineColor; + vector<TrackOutline> m_outlines; struct ClosingSymbol { |