-
Notifications
You must be signed in to change notification settings - Fork 6
/
TouchEvent.h
74 lines (59 loc) · 921 Bytes
/
TouchEvent.h
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
/*
* TouchEvent.h
*
* Created on: 22 Jul 2018
* Author: andrewcapon
*/
#ifndef TOUCHEVENT_H_
#define TOUCHEVENT_H_
#include "CAD.h"
class TouchEvent
{
public:
TouchEvent(uint8_t uTouchId);
TouchEvent(uint8_t uTouchId, int32_t nX, int32_t nY, int32_t m_nInitialArea);
virtual ~TouchEvent();
void SetActive(bool bActive)
{
m_bActive = bActive;
}
bool GetActive(void)
{
return m_bActive;
}
uint8_t GetTouchId(void)
{
return m_uTouchId;
}
void SetX(int32_t nX)
{
m_nX = nX;
}
int32_t GetX(void)
{
return m_nX;
}
void SetY(int32_t nY)
{
m_nY = nY;
}
int32_t GetY(void)
{
return m_nY;
}
void SetInitialArea(int32_t nInitialArea)
{
m_nInitialArea = nInitialArea;
}
int32_t GetInitialArea(void)
{
return m_nInitialArea;
}
private:
uint8_t m_uTouchId;
bool m_bActive;
int32_t m_nX;
int32_t m_nY;
int32_t m_nInitialArea;
};
#endif /* TOUCHEVENT_H_ */