diff --git a/src/simplified/xf/core/customevent.cpp b/src/simplified/xf/core/customevent.cpp index 7580c78..f15e9e5 100644 --- a/src/simplified/xf/core/customevent.cpp +++ b/src/simplified/xf/core/customevent.cpp @@ -1,3 +1,15 @@ #include "xf/customevent.h" -// TODO: Implement code for XFCustomEvent class +// TODO done: Implement code for XFCustomEvent class + + +XFCustomEvent::XFCustomEvent(int id, interface::XFBehavior *pBehavior): + XFEvent(XFEventType::Unknown, id){ + setBehavior(pBehavior); +} + +bool XFCustomEvent::deleteAfterConsume() const { + return bDeleteAfterConsume_; +} + + diff --git a/src/simplified/xf/core/defaulttransition.cpp b/src/simplified/xf/core/defaulttransition.cpp index 99d335b..e08e854 100644 --- a/src/simplified/xf/core/defaulttransition.cpp +++ b/src/simplified/xf/core/defaulttransition.cpp @@ -1,3 +1,12 @@ #include "xf/defaulttransition.h" -// TODO: Implement code for XFDefaultTransition class +// TODO done: Implement code for XFDefaultTransition class + +XFDefaultTransition::XFDefaultTransition(): + XFEvent(XFEventType::DefaultTransition) { + +} + +bool XFDefaultTransition::deleteAfterConsume() const { + return true; +} diff --git a/src/simplified/xf/core/initialevent.cpp b/src/simplified/xf/core/initialevent.cpp index b761b39..d7f343b 100644 --- a/src/simplified/xf/core/initialevent.cpp +++ b/src/simplified/xf/core/initialevent.cpp @@ -1,3 +1,12 @@ #include "xf/initialevent.h" -// TODO: Implement code for XFInitialEvent class +// TODO done: Implement code for XFInitialEvent class + +XFInitialEvent::XFInitialEvent(): + XFEvent(XFEventType::Initial) { + +} + +bool XFInitialEvent::deleteAfterConsume() const { + return true; +} diff --git a/src/simplified/xf/core/timeout.cpp b/src/simplified/xf/core/timeout.cpp index 2f2202f..717bad5 100644 --- a/src/simplified/xf/core/timeout.cpp +++ b/src/simplified/xf/core/timeout.cpp @@ -4,6 +4,7 @@ XFTimeout::XFTimeout(int id, int interval, interface::XFBehavior *pBehavior): XFEvent(XFEventType::Timeout, id), interval_(interval) { + setBehavior(pBehavior); } bool XFTimeout::operator ==(const XFTimeout &timeout) const {