AnalogClock and handleTickEvent()
Hi all,
I would like to know how to use "handleTickEvent" on AnalogClock.
I draw a screen with a Analog but thisone never upate itself.
I see other examples witch use handleTickEvent to execute a new render but all has the same configurations..
The strange thing is that In my code this routine is called for about 10 times only when touchscreen is pressed.
this is my code:
void Screen2View::handleTickEvent()
{
tickCounter++;
if (tickCounter % 60 == 0)
{
if (++analogSeconds >= 60)
{
analogSeconds = 0;
if (++analogMinutes >= 60)
{
analogMinutes = 0;
if (++analogHours >= 24)
{
analogHours = 0;
}
}
}
// Update the clocks
analogClock1.setTime24Hour(analogHours, analogMinutes, analogSeconds);
}
}class Screen2View : public Screen2ViewBase
{
public:
Screen2View();
virtual ~Screen2View() {}
virtual void setupScreen();
virtual void tearDownScreen();
virtual void handleTickEvent();
protected:
int tickCounter;
int analogHours;
int analogMinutes;
int analogSeconds;
};I don't understand the reason : Must I add something else in my code? (I copy the settings from an 743I-EVAL template).
thanks in advance.