Changeset 15 for trunk/src/helpers/timer.c
- Timestamp:
- Dec 11, 2000, 8:54:20 AM (25 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/helpers/timer.c
r14 r15 71 71 #define INCL_DOSPROCESS 72 72 #define INCL_DOSSEMAPHORES 73 #define INCL_DOSMISC 73 74 #define INCL_DOSERRORS 74 75 #include <os2.h> … … 190 191 * is stopped thru tmrStopTimer, which then 191 192 * sets the thread's fExit flag to TRUE. 193 * 194 *@@changed V0.9.7 (2000-12-08) [umoeller]: got rid of dtGetULongTime 192 195 */ 193 196 … … 244 247 { 245 248 PXTIMER pTimer = (PXTIMER)pTimerNode->pItemData; 246 ULONG ulTimeNow = dtGetULongTime(); 249 ULONG ulTimeNow; 250 DosQuerySysInfo(QSV_MS_COUNT, QSV_MS_COUNT, 251 &ulTimeNow, sizeof(ulTimeNow)); 247 252 248 253 if (pTimer->ulNextFire < ulTimeNow) … … 357 362 * 358 363 * -- The caller must call LockTimers() first. 359 *360 *@@added V0.9.7 (2000-12-04) [umoeller]361 364 */ 362 365 … … 385 388 * 386 389 * The timer is _not_ stopped automatically 387 * when the wi dgetis destroyed.388 * 389 *@@ added V0.9.7 (2000-12-04) [umoeller]390 * when the window is destroyed. 391 * 392 *@@changed V0.9.7 (2000-12-08) [umoeller]: got rid of dtGetULongTime 390 393 */ 391 394 … … 432 435 { 433 436 // exists already: reset only 434 pTimer->ulNextFire = dtGetULongTime() + ulTimeout; 437 ULONG ulTimeNow; 438 DosQuerySysInfo(QSV_MS_COUNT, QSV_MS_COUNT, 439 &ulTimeNow, sizeof(ulTimeNow)); 440 pTimer->ulNextFire = ulTimeNow + ulTimeout; 435 441 usrc = pTimer->usTimerID; 436 442 } … … 441 447 if (pTimer) 442 448 { 449 ULONG ulTimeNow; 450 DosQuerySysInfo(QSV_MS_COUNT, QSV_MS_COUNT, 451 &ulTimeNow, sizeof(ulTimeNow)); 443 452 pTimer->usTimerID = usTimerID; 444 453 pTimer->hwndTarget = hwnd; 445 454 pTimer->ulTimeout = ulTimeout; 446 pTimer->ulNextFire = dtGetULongTime()+ ulTimeout;455 pTimer->ulNextFire = ulTimeNow + ulTimeout; 447 456 448 457 lstAppendItem(&G_llTimers, … … 476 485 * 477 486 * Returns TRUE if the timer was stopped. 478 *479 *@@added V0.9.7 (2000-12-04) [umoeller]480 487 */ 481 488 … … 523 530 * that you should call during WM_DESTROY of 524 531 * a window that has started timers. 525 *526 *@@added V0.9.7 (2000-12-04) [umoeller]527 532 */ 528 533
Note:
See TracChangeset
for help on using the changeset viewer.