- Timestamp:
- Oct 3, 2001, 3:47:59 PM (24 years ago)
- Location:
- trunk/src/winmm
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/winmm/os2timer.cpp
r5358 r6933 1 /* $Id: os2timer.cpp,v 1.1 8 2001-03-23 16:23:44sandervl Exp $ */1 /* $Id: os2timer.cpp,v 1.19 2001-10-03 13:47:58 sandervl Exp $ */ 2 2 3 3 /* … … 225 225 OS2Timer::OS2Timer() : TimerSem(0), TimerHandle(0), hTimerThread(0), 226 226 clientCallback(NULL), TimerStatus(Stopped), fFatal(FALSE), 227 next(NULL) 227 next(NULL), timerID(0) 228 228 { 229 229 dprintf(("WINMM:OS2Timer: OS2Timer::OS2Timer(%08xh)\n", … … 416 416 { 417 417 selTIB = SetWin32TIB(); 418 clientCallback((UINT)t his, 0, userData, 0, 0);418 clientCallback((UINT)timerID, 0, userData, 0, 0); 419 419 SetFS(selTIB); 420 420 } -
trunk/src/winmm/os2timer.h
r6728 r6933 1 /* $Id: os2timer.h,v 1.1 0 2001-09-16 19:27:24 phallerExp $ */1 /* $Id: os2timer.h,v 1.11 2001-10-03 13:47:58 sandervl Exp $ */ 2 2 3 3 #ifndef __OS2TIMER_H__ … … 107 107 void KillTimer(); 108 108 109 110 DWORD getTimerID() { return timerID; }; 111 void setTimerID(DWORD id) { timerID = id; }; 112 109 113 protected: 110 114 … … 120 124 BOOL fFatal; 121 125 int TimerStatus; 126 DWORD timerID; 122 127 enum { 123 128 InActive = 0, -
trunk/src/winmm/time.cpp
r6728 r6933 1 /* $Id: time.cpp,v 1.1 3 2001-09-16 19:27:25 phallerExp $ */1 /* $Id: time.cpp,v 1.14 2001-10-03 13:47:59 sandervl Exp $ */ 2 2 3 3 /* … … 18 18 #include <odinwrap.h> 19 19 #include <misc.h> 20 #include <handlemanager.h> 20 21 21 22 #include "os2timer.h" … … 138 139 UINT, IDEvent) 139 140 { 140 dprintf(("WINMM:timeKillEvent\n")); 141 141 OS2Timer *os2timer = NULL; 142 143 if(HMHandleTranslateToOS2(IDEvent, (PULONG)&os2timer) != NO_ERROR) { 144 dprintf(("invalid timer id")); 145 return TIMERR_NOERROR; //TODO: should we return an error here?? 146 } 147 HMHandleFree(IDEvent); 142 148 // return OS2Timer::killEvent(UINT IDEvent) 143 149 144 delete ((OS2Timer *)IDEvent);150 delete os2timer; 145 151 return TIMERR_NOERROR; 146 152 } … … 167 173 { 168 174 OS2Timer *timer; 175 ULONG timerID = 0; 169 176 170 177 // @@@PH 1999/10/26 hack for RA95 … … 200 207 return(0); 201 208 209 if(HMHandleAllocate(&timerID, (ULONG)timer) != NO_ERROR) { 210 dprintf(("HMHandleAllocate failed!!")); 211 delete timer; 212 return 0; 213 } 214 215 timer->setTimerID(timerID); 202 216 if(timer->StartTimer(wDelay, wResolution, lptc, dwUser, fuEvent) == FALSE) 203 217 { … … 206 220 return(0); 207 221 } 208 return(MMRESULT)timer ;222 return(MMRESULT)timerID; 209 223 } 210 224
Note:
See TracChangeset
for help on using the changeset viewer.