# HG changeset patch # User sam # Date 1718427425 -25200 # Node ID 6a7f09909a37d0afb5e8c0ecdb5f3296f430055a # Parent af18922b416d36bf1475155bbb313f31bd3743d3# Parent d7891cf88359ecfca77b6c20caa693eca7067b18 merge diff -r af18922b416d -r 6a7f09909a37 semicongine/platform/windows/audio.nim --- a/semicongine/platform/windows/audio.nim Sat Jun 15 11:55:56 2024 +0700 +++ b/semicongine/platform/windows/audio.nim Sat Jun 15 11:57:05 2024 +0700 @@ -25,7 +25,7 @@ wBitsPerSample: 16, cbSize: 0, ) - checkWinMMResult waveOutOpen(addr result.handle, WAVE_MAPPER, addr format, DWORD_PTR(0), DWORD_PTR(0), CALLBACK_NULL) + CheckWinMMResult waveOutOpen(addr result.handle, WAVE_MAPPER, addr format, DWORD_PTR(0), DWORD_PTR(0), CALLBACK_NULL) for i in 0 ..< buffers.len: result.buffers.add WAVEHDR( @@ -34,13 +34,13 @@ dwLoops: 1, ) for i in 0 ..< result.buffers.len: - checkWinMMResult waveOutPrepareHeader(result.handle, addr result.buffers[i], UINT(sizeof(WAVEHDR))) - checkWinMMResult waveOutWrite(result.handle, addr result.buffers[i], UINT(sizeof(WAVEHDR))) + CheckWinMMResult waveOutPrepareHeader(result.handle, addr result.buffers[i], UINT(sizeof(WAVEHDR))) + CheckWinMMResult waveOutWrite(result.handle, addr result.buffers[i], UINT(sizeof(WAVEHDR))) proc WriteSoundData*(soundDevice: var NativeSoundDevice, buffer: int) = while (soundDevice.buffers[buffer].dwFlags and WHDR_DONE) == 0: sleep(1) - checkWinMMResult waveOutWrite(soundDevice.handle, addr soundDevice.buffers[buffer], UINT(sizeof(WAVEHDR))) + CheckWinMMResult waveOutWrite(soundDevice.handle, addr soundDevice.buffers[buffer], UINT(sizeof(WAVEHDR))) proc CloseSoundDevice*(soundDevice: var NativeSoundDevice) = for i in 0 ..< soundDevice.buffers.len: diff -r af18922b416d -r 6a7f09909a37 semicongine/platform/windows/window.nim --- a/semicongine/platform/windows/window.nim Sat Jun 15 11:55:56 2024 +0700 +++ b/semicongine/platform/windows/window.nim Sat Jun 15 11:57:05 2024 +0700 @@ -129,7 +129,7 @@ proc Size*(window: NativeWindow): (int, int) = var rect: RECT - checkWin32Result GetWindowRect(window.hwnd, addr(rect)) + CheckWin32Result GetWindowRect(window.hwnd, addr(rect)) (int(rect.right - rect.left), int(rect.bottom - rect.top)) proc PendingEvents*(window: NativeWindow): seq[Event] =