PDA

View Full Version : Timer calls in API



avid
June 11th, 2004, 10:57 AM
Ben,

If you are changing the driver SDK again, could I restate my request for a timer API, e.g.:

virtual bool NetRemoteDriver::OnTimer(void* param);
INetRemoteActions::SetTimer(DWORD ticks, void* param);

So I would call SetTimer to request a callback on my implementation of OnTimer some specified ticks later.

I could see uses for this for:
1) Throttling the messages to a server when responding to rapid slider movement.
2) Smooth scrolling when dragging a list. [I use my own Windows handle for this]
3) Cycling or marquee text.
4) Messages that cycle, or flash or disappear after a brief period.
5) Etc.

Brian

Mastiff
June 11th, 2004, 07:48 PM
Please send stuff like this as a private message next time! My brain just crashed with a huge blue screen of death! No, wait a minute! That's just the wallpaper in the "throne room"! :oops: :wink:

avid
June 13th, 2004, 09:48 AM
Ben,

It looks as though this proposed enhancement might be the answer to Mastiff's problem we are discussing under http://www.netremote.org/phpBB2/viewtopic.php?t=1073

Any chance?

Brian

Mastiff
June 13th, 2004, 09:53 AM
Interesting! In that case I can take a few brain short circuits... :oops:

Ben S
June 13th, 2004, 11:32 AM
Sure. I should have something to you this week with the changes (and I'll throw this in if you need it).

This timer will only fire once, right?

avid
June 13th, 2004, 11:39 AM
That's right. Effectively I want a delayed callback. For each call of SetTimer, you will call OnTimer the specified ticks (ms) later.

Thanks for rushing this in - it is the proper solution to Mastiff's problem and opens up new opportunities.

Brian

Ben S
June 13th, 2004, 11:50 AM
Okay. You'll see it this week.