blob: ed2cec5c71a807dbd92feeff5b4c1cc5417ac749 (
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
|
#pragma once
#include "map/user_mark.hpp"
class GuideMark : public UserMark
{
public:
enum class Type
{
City,
Outdoor
};
explicit GuideMark(m2::PointD const & ptOrg);
void SetGuideType(Type type);
Type GetType() const { return m_type; }
void SetIsDownloaded(bool isDownloaded);
bool GetIsDownloaded() const { return m_isDownloaded; }
void SetGuideId(std::string guideId);
std::string GetGuideId() const { return m_guideId; }
void SetDepth(float depth);
// df::UserPointMark overrides.
float GetDepth() const override { return m_depth; }
df::DepthLayer GetDepthLayer() const override { return df::DepthLayer::GuidesMarkLayer; }
drape_ptr<SymbolNameZoomInfo> GetSymbolNames() const override;
m2::PointD GetPixelOffset() const override;
private:
void Update();
float m_depth = 0.0f;
std::string m_guideId;
Type m_type = Type::City;
bool m_isDownloaded = false;
SymbolNameZoomInfo m_symbolInfo;
};
class GuidesClusterMark : public UserMark
{
public:
explicit GuidesClusterMark(m2::PointD const & ptOrg);
void SetGuidesCount(uint32_t cityGuidesCount, uint32_t outdoorGuidesCount);
void SetDepth(float depth);
// df::UserPointMark overrides.
float GetDepth() const override { return m_depth; }
df::DepthLayer GetDepthLayer() const override { return df::DepthLayer::GuidesMarkLayer; }
drape_ptr<SymbolNameZoomInfo> GetSymbolNames() const override;
drape_ptr<TitlesInfo> GetTitleDecl() const override;
private:
void Update();
float m_depth = 0.0f;
uint32_t m_cityGuidesCount = 0;
uint32_t m_outdoorGuidesCount = 0;
SymbolNameZoomInfo m_symbolInfo;
dp::TitleDecl m_titleDecl;
};
class GuideSelectionMark : public UserMark
{
public:
explicit GuideSelectionMark(m2::PointD const & ptOrg);
df::DepthLayer GetDepthLayer() const override { return df::DepthLayer::GuidesBottomMarkLayer; }
drape_ptr<SymbolNameZoomInfo> GetSymbolNames() const override { return nullptr; }
drape_ptr<ColoredSymbolZoomInfo> GetColoredSymbols() const override;
private:
ColoredSymbolZoomInfo m_coloredInfo;
};
|