[maemo-developers] sensing change in System Clock using Qt
From: ibrahim ibrahim.ali at asgatech.comDate: Sun Jan 31 09:41:50 EET 2010
- Previous message: sensing change in System Clock using Qt
- Next message: sensing change in System Clock using Qt
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Remi.Denis-Courmont at nokia.com wrote: > Hello, > > ----- Message d'origine ----- > >> But the problem that can face me is the case when the user changes his >> clock settings (i.e adjust phone's time to a different time). in this >> case, the timer that has been set to some fixed duration can go wrong. >> > > As a general rule, delay measurements should be done with the monotonic clock, not the wall clock (the real-time clock). As far as I know, Qt timers already do so internally. But of course, your own code should never request and use the wall clock for time measurements. > > I don't think I follow you! What do you mean by monotonic clock ? If I don't depend on the system's clock to get current time, where else can I get it from ? Let me explain my problem again briefly, I want to know the current time, calculate some future durations depending on it. Then I figure out the time left to the upcoming duration and set it as interval to a QTimer Object. But I'm afraid that user may change the system clock (adjust the clock) So that my preset time will be invalid.
- Previous message: sensing change in System Clock using Qt
- Next message: sensing change in System Clock using Qt
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]