Changeset 28:9b3c2d3ea9f3 in vscpl for src/hu/varadiistvan/scpl/io/_win32/Event.h
- Timestamp:
- 12/15/22 15:56:11 (17 months ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/hu/varadiistvan/scpl/io/_win32/Event.h
r6 r28 133 133 inline Event::Event(EventFailable& eventFailable) : 134 134 eventFailable(eventFailable), 135 handle( CreateEvent(0, true, false, 0)),135 handle(eventFailable.createEvent()), 136 136 waiter(0) 137 137 { … … 144 144 { 145 145 removeFromWaiter(); 146 CloseHandle(handle);146 eventFailable.destroyEvent(handle); 147 147 } 148 148 … … 172 172 inline void Event::fire() 173 173 { 174 if (! SetEvent(handle)) {174 if (!eventFailable.setEvent(handle)) { 175 175 eventFailable.setErrorCode(GetLastError()); 176 176 } … … 181 181 inline bool Event::clear() 182 182 { 183 if (! ResetEvent(handle)) {183 if (!eventFailable.resetEvent(handle)) { 184 184 eventFailable.setErrorCode(GetLastError()); 185 185 return false;
Note:
See TracChangeset
for help on using the changeset viewer.