Guiliani  Version 2.6 revision 7293 (documentation build 12)
GUIMultitouchBehaviour.h
1/*
2* Copyright (C) TES Electronic Solutions GmbH,
3* All Rights Reserved.
4* Contact: info@guiliani.de
5*
6* This file is part of the Guiliani HMI framework
7* for the development of graphical user interfaces on embedded systems.
8*/
9
10#ifndef __GUI_MULTITOUCH_BEHAVIOUR_H__
11#define __GUI_MULTITOUCH_BEHAVIOUR_H__
12
13#include "GUIBehaviourDecorator.h"
15
18{
19public:
22 {
25 };
26
27public:
34 const MultitouchType_t& eType,
35 const eC_Bool& bKeepCenter,
36 const eC_Value& vFactor);
37
39
40#if defined(GUILIANI_STREAM_GUI)
45 virtual void ReadFromStream();
46#endif
47
48#if defined(GUILIANI_WRITE_GUI)
54 virtual void WriteToStream(const eC_Bool bWriteClassID=false);
55#endif
56
60 void SetType(const MultitouchType_t& eType);
61
66
70 void SetKeepCenter(const eC_Bool& bKeepCenter);
71
75 eC_Bool GetKeepCenter() const;
76
82 void SetFactor(const eC_Value& vFactor);
83
87 eC_Value GetFactor() const;
88
89protected:
90 virtual eC_Bool DoScale(const eC_Value& vDelta);
91
92 virtual eC_Bool DoScroll(
93 const eC_Value& vAbsX,
94 const eC_Value& vAbsY,
95 const eC_Value& vDelta,
96 const eC_Bool& bModifierActive);
97
98private:
99 MultitouchType_t m_eType;
100 eC_Bool m_bKeepCenter;
101 eC_Value m_vFactor;
102};
103
104#endif
Helper Macros in Guiliani
GUIBehaviourDecorator base class.
Definition: GUIBehaviourDecorator.h:78
Behaviour for processing object state changes.
Definition: GUIMultitouchBehaviour.h:18
MultitouchType_t GetType() const
eC_Value GetFactor() const
MultitouchType_t
enum for gesture type
Definition: GUIMultitouchBehaviour.h:22
@ MT_SCALE
scaling
Definition: GUIMultitouchBehaviour.h:23
@ MT_SCROLL
scrolling
Definition: GUIMultitouchBehaviour.h:24
CGUIMultitouchBehaviour(const MultitouchType_t &eType, const eC_Bool &bKeepCenter, const eC_Value &vFactor)
eC_Bool GetKeepCenter() const
virtual void WriteToStream(const eC_Bool bWriteClassID=false)
void SetType(const MultitouchType_t &eType)
virtual eC_Bool DoScroll(const eC_Value &vAbsX, const eC_Value &vAbsY, const eC_Value &vDelta, const eC_Bool &bModifierActive)
virtual eC_Bool DoScale(const eC_Value &vDelta)
virtual void ReadFromStream()
void SetFactor(const eC_Value &vFactor)
void SetKeepCenter(const eC_Bool &bKeepCenter)