nanogui: microwindows stops events for the duration of system clock setting back


Previous by date: 3 Aug 2004 11:39:07 +0100 do anybody has experience to cross-compile libwww?, Zeng_Pengcheng
Next by date: 3 Aug 2004 11:39:07 +0100 chinese fonts howto for microwindows?, pclili
Previous in thread: 3 Aug 2004 11:39:07 +0100 microwindows stops events for the duration of system clock setting back, Kinz Elektronik
Next in thread: 3 Aug 2004 11:39:07 +0100 Re: microwindows stops events for the duration of system clock setting back, Kinz Elektronik

Subject: Re: [nanogui] microwindows stops events for the duration of system clock setting back
From: ####@####.####
Date: 3 Aug 2004 11:39:07 +0100
Message-Id: <200408031239.04023.gerd.mitlaender@daum-electronic.de>

Hi...

i solved it that way:

I've included the following function in winuser.c:

BOOL WINAPI RestartTimers(void)
{
	int index;
	DWORD ticks = GetTickCount();
	
	for (index = 0; index < MAX_TIMER_COUNT; index++)
	{
		if(timer[index].uTimeout)
		{
			timer[index].dwClockExpires = ticks + timer[index].uTimeout;
		}
	}
  
  return TRUE;
}

But i've already "hacked" the timers to be able to run 5 (= MAX_TIMER_COUNT) 
of them. I think you must only do a:

if(timer.uTimeout)
{
	timer.dwClockExpires = ticks + timer.uTimeout;
}

to restart your timer in RestartTimers. Call the function after you've set the 
system time.

Regards,

Gerd

PS: The timer is restarted so you may get one event less if the timer was 
shortly before timing out.

Am Dienstag, 3. August 2004 11:44 schrieb Kinz Elektronik:
> Hi,
>
> I have the problem when the system clock is set back that microwindows
> stops to send the timer and many drawings aren't updated for the
> duration
> the system clock is set back.
> This problem can be tested with the demos (mdemo).
> Is there any workaround to solve this problem (function to reset the
> timers, ...)?
> I am using the microwindows version 0.89 is this solved in the current
> version?
>
> Regards, Robert
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ####@####.####
> For additional commands, e-mail: ####@####.####

-- 
Mit freundlichem Gruß,

Gerd Mitländer

Dipl.-Ing. (FH) Daten- und Informationstechnik

daum forschung und entwicklung gmbh
Flugplatzstr. 100
D-90768 Fürth

Tel. +49-(0)911-97536-26
Fax. +49-(0)911-97536-96
Mail ####@####.####

Previous by date: 3 Aug 2004 11:39:07 +0100 do anybody has experience to cross-compile libwww?, Zeng_Pengcheng
Next by date: 3 Aug 2004 11:39:07 +0100 chinese fonts howto for microwindows?, pclili
Previous in thread: 3 Aug 2004 11:39:07 +0100 microwindows stops events for the duration of system clock setting back, Kinz Elektronik
Next in thread: 3 Aug 2004 11:39:07 +0100 Re: microwindows stops events for the duration of system clock setting back, Kinz Elektronik


Powered by ezmlm-browse 0.20.