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

api_mark_point.hpp « map - github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 12870c2ef9383bfb358ba5d51b48295eefbc4ca9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#pragma once

#include "map/user_mark.hpp"
#include "map/user_mark_container.hpp"

#include "geometry/point2d.hpp"

#include "std/string.hpp"

namespace style
{

// Fixes icons which are not supported by MapsWithMe.
string GetSupportedStyle(string const & s, string const & context, string const & fallback);
// Default icon.
string GetDefaultStyle();

} // style

class ApiMarkPoint : public UserMark
{
public:
  ApiMarkPoint(m2::PointD const & ptOrg, UserMarkContainer * container);

  ApiMarkPoint(string const & name, string const & id, string const & style,
               m2::PointD const & ptOrg, UserMarkContainer * container);

  string GetSymbolName() const override;
  UserMark::Type GetMarkType() const override;
  m2::PointD GetPixelOffset() const override;

  string const & GetName() const { return m_name; }
  void SetName(string const & name) { m_name = name; }

  string const & GetID() const { return m_id; }
  void SetID(string const & id) { m_id = id; }

  void SetStyle(string const & style) { m_style = style; }
  string const & GetStyle() const { return m_style; }

private:
  string m_name;
  string m_id;
  string m_style;
};