Behaviour for processing object state changes. More...
#include <GUIMultitouchBehaviour.h>
Public Types | |
enum | MultitouchType_t { MT_SCALE , MT_SCROLL } |
enum for gesture type More... | |
Public Member Functions | |
CGUIMultitouchBehaviour (const MultitouchType_t &eType, const eC_Bool &bKeepCenter, const eC_Value &vFactor) | |
eC_Value | GetFactor () const |
eC_Bool | GetKeepCenter () const |
MultitouchType_t | GetType () const |
virtual void | ReadFromStream () |
void | SetFactor (const eC_Value &vFactor) |
void | SetKeepCenter (const eC_Bool &bKeepCenter) |
void | SetType (const MultitouchType_t &eType) |
virtual void | WriteToStream (const eC_Bool bWriteClassID=false) |
![]() | |
virtual | ~CGUIBehaviourDecorator () |
virtual CGUIBehaviourDecorator * | Clone () const |
virtual eC_Bool | IsCompositeBehaviour () const |
![]() | |
virtual eC_Bool | DoScale (const eC_Value &vDelta) |
virtual eC_Bool | DoUserEvent (CGUIEvent *const pEvent) |
virtual void | OnCreate () |
virtual void | OnDataPool (const DataPoolResource_t &eID) |
virtual void | OnDelete () |
virtual void | OnHide () |
virtual void | OnShow () |
virtual eC_Bool | DoClick (const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | DoLongClick (const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | DoDoubleClick (const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | DoButtonDown (const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | DoButtonUp (const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | DoDrag (const eC_Value &vDeltaX=eC_FromInt(-1), const eC_Value &vDeltaY=eC_FromInt(-1), const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | DoDragEnd (const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | DoMouseEnter (const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | DoMouseLeave (const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | DoMouseMove (const eC_Value &vAbsX=eC_FromInt(-1), const eC_Value &vAbsY=eC_FromInt(-1)) |
virtual eC_Bool | FocusPrevious (CGUIObject *const pRefObj=NULL, const eC_Bool &bSubTreeOfRefObjDone=false) |
virtual eC_Bool | FocusNext (CGUIObject *const pRefObj=NULL, const eC_Bool &bSubTreeOfRefObjDone=false) |
virtual void | GetFocus () |
virtual void | LoseFocus () |
virtual eC_Bool | Decrease () |
virtual eC_Bool | Increase () |
virtual eC_Bool | DoKeyDown (const GUIKeyIdentifier_t &eKeyIdentifier, const eC_UInt &uiModifiers) |
virtual eC_Bool | DoKeyUp (const GUIKeyIdentifier_t &eKeyIdentifier, const eC_UInt &uiModifiers) |
virtual eC_Bool | DoChar (const eC_UInt &uiKey, const GUIKeyIdentifier_t &eKeyIdentifier, const eC_UInt &uiModifiers) |
![]() | |
const eC_String & | GetXMLTag () const |
virtual void | ReadFromStream () |
void | SetXMLTag (const eC_String &kXMLTag) |
virtual void | WriteToStream (const eC_Bool bWriteClassID=false) |
Protected Member Functions | |
virtual eC_Bool | DoScale (const eC_Value &vDelta) |
virtual eC_Bool | DoScroll (const eC_Value &vAbsX, const eC_Value &vAbsY, const eC_Value &vDelta, const eC_Bool &bModifierActive) |
![]() | |
CGUIBehaviourDecorator (CGUIObject *const pkObject=NULL) | |
CGUIBehaviourDecorator (const CGUIBehaviourDecorator &kSource) | |
virtual void | AssociatedObjectChanges (CGUIObject *const pkNewAssociatedObject) |
CGUIObject * | GetAssociatedObject () const |
![]() | |
eC_UInt | ReadStreamingHeader (const eC_UInt &uiClassVersion, const eC_UInt &uiClassMinVersion=0) const |
void | WriteStreamingFooter (const eC_Bool &bWriteClassID) const |
void | WriteStreamingHeader (const eC_Bool &bWriteClassID, const eC_Char *const pkClassIDTag, const eC_Int &iClassID, const eC_UInt &uiClassVersion) const |
Additional Inherited Members | |
![]() | |
static UUID_t | GenerateUUID () |
![]() | |
static const eC_Char | XMLTAG_BEHAVIOURCLASSID [] |
XML tag to be used when writing a behaviour class ID into a stream. | |
static const eC_Char | XMLTAG_BEHAVIOURCOUNT [] |
XML tag for count. | |
![]() | |
static const eC_Char | XMLTAG_CLASSVERSION [] |
Behaviour for processing object state changes.
CGUIMultitouchBehaviour::CGUIMultitouchBehaviour | ( | const MultitouchType_t & | eType, |
const eC_Bool & | bKeepCenter, | ||
const eC_Value & | vFactor | ||
) |
Constructor
eType | type of gesture |
bKeepCenter | if true the center of the object will be retained |
vFactor | factor for gesture |
|
protectedvirtual |
Slot for handling scaling-events will be called if a gesture has been detected which results in scaling
vDelta | delta for span (radius of circle around touches) |
Reimplemented from CGUIBehaviour.
|
protectedvirtual |
Called when the mouse wheel was scrolled
vAbsX | X-position of the mouse in screen coordinates |
vAbsY | Y-position of the mouse in screen coordinates |
vDelta | number of pixels for scroll |
bModifierActive | if true the scroll modifier is active (e.g. left/right instead of up/down) |
Reimplemented from CGUIBehaviour.
eC_Value CGUIMultitouchBehaviour::GetFactor | ( | ) | const |
Get the factor used for scaling and scrolling
eC_Bool CGUIMultitouchBehaviour::GetKeepCenter | ( | ) | const |
Get if the object should keep its center
MultitouchType_t CGUIMultitouchBehaviour::GetType | ( | ) | const |
Get the current set type of processing
|
virtual |
Reads all attributes from streaming file. This method is called by CGUIFactoryManager after one of the registered factories has created an instance of this class.
Reimplemented from CGUIStreamableObject.
void CGUIMultitouchBehaviour::SetFactor | ( | const eC_Value & | vFactor | ) |
Set the factor for scaling and scrolling
vFactor | the factor used for scaling and scrolling for scaling this factor will be multiplied with the delta movement for scrolling this factor is the number of pixels the object is moved |
void CGUIMultitouchBehaviour::SetKeepCenter | ( | const eC_Bool & | bKeepCenter | ) |
Set the keep center position when resizing the object
bKeepCenter | if true the object will keep its center position |
void CGUIMultitouchBehaviour::SetType | ( | const MultitouchType_t & | eType | ) |
Set the type of processing, either scaling or scrolling
eType | scaling or scrolling |
|
virtual |
Writes all attributes to the streaming file. A CGUIStreamWriter has to be initialized first.
bWriteClassID | This flag is used to select if writing of command class ID, leading and trailing tags is performed. |
Reimplemented from CGUIStreamableObject.