void MyTimer::Notify()
{
+ //This will be called each time the timer finishes a countdown
_box->Change();
_box->bbSignalOutputModification(std::string("Out"));
}
void ImageSwitcherBox::Change()
{
+ //Just changes the images each time the timer finishes a countdown
+
if(change == false)
{
bbSetOutputOut(bbGetInputIn2());
myTimer->Start(time);
oldTime = time;
}
- /*
- if(oldTime != time && myTimer !=NULL)
- {
- myTimer->Stop();
- myTimer->Start(time);
- oldTime = time;
- }*/
-
+
if(!_on)
{
myTimer->Stop();
}
void ImageSwitcherBox::CreateWidget(wxWindow* parent)
{
+ //Creates a simple text widget because it is necesary that a non-empty widget exists for creatingh the thread of the timer.
bbSetOutputWidget( new wxStaticText(parent, -1, _T("Image Switcher")) );
}
void ImageSwitcherBox::bbUserSetDefaultValues()