SymbiSoft / mosync

Automatically exported from code.google.com/p/mosync
0 stars 0 forks source link

addTimer doesn't work in symbian #740

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1.Application exit inmediatly

In J2ME works fine.

Original issue reported on code.google.com by jaz...@gmail.com on 8 Jul 2010 at 8:22

GoogleCodeExporter commented 8 years ago
To reproduce your issue, we'll need to know which version of MoSync you're 
using. We'll also need the source code to a program which exhibits the problem. 
Thanks for your assistance.

Original comment by fredrik....@gtempaccount.com on 12 Jul 2010 at 9:17

GoogleCodeExporter commented 8 years ago
I'm using nigthy build 1606

class LocationTimer: public TimerListener{
public:
    LocationTimer();
    void runTimerEvent();
};

void LocationTimer::runTimerEvent(){
  printf("TimerEvent");
}
.....

MyMoblet::MyMoblet() {
  LLT = new LocationTimer();
  addTimer(LLT, 3600000, -1);
}

Original comment by jaz...@gmail.com on 12 Jul 2010 at 6:31

GoogleCodeExporter commented 8 years ago

Original comment by miles.mi...@gtempaccount.com on 14 Jul 2010 at 11:57

GoogleCodeExporter commented 8 years ago
This is due to the fact that Symbian's timers work on signed 32-bit 
MICRO-seconds, rather than milliseconds. Thus, any timer interval beyond 
(2^31/1000, about 2100000) milliseconds will wrap around to negative, which 
triggers a Symbian Panic.

It should be fixable. In the meantime, try shortening your timer interval to 
below 2 million.

Original comment by fredrik....@gtempaccount.com on 14 Jul 2010 at 12:11