From 771bef794b7edb7ef6cbe78acf2ee93b39f10f74 Mon Sep 17 00:00:00 2001 From: Thomas Grill Date: Fri, 11 Feb 2005 04:56:07 +0000 Subject: Max: use high-priority click instead of qelem for message-posting fixed flext::Timer::At method svn path=/trunk/; revision=2566 --- externals/grill/flext/source/fltimer.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'externals/grill/flext/source/fltimer.cpp') diff --git a/externals/grill/flext/source/fltimer.cpp b/externals/grill/flext/source/fltimer.cpp index c317df45..294da438 100755 --- a/externals/grill/flext/source/fltimer.cpp +++ b/externals/grill/flext/source/fltimer.cpp @@ -162,9 +162,11 @@ bool flext::Timer::At(double tm,void *data,bool dopast) userdata = data; period = 0; #if FLEXT_SYS == FLEXT_SYS_PD - const double ms = tm*1000.; - if(dopast || clock_gettimesince(ms) <= 0) - clock_set(clk,ms); + const double systm = clock_gettimesince(0); + double df = tm*1000.-systm; + if(dopast && df < 0) df = 0; + if(df >= 0) + clock_delay(clk,df); #elif FLEXT_SYS == FLEXT_SYS_MAX const double ms = tm*1000.; double cur; -- cgit v1.2.1