Mercurial > games > semicongine
changeset 1079:87b72668d723
merge
author | sam <sam@basx.dev> |
---|---|
date | Wed, 03 Apr 2024 19:53:20 +0700 |
parents | 84d9822c028d (current diff) 799a630aa2bb (diff) |
children | 33374c4350e7 |
files | |
diffstat | 1 files changed, 6 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/semicongine/platform/windows/window.nim Wed Apr 03 19:49:42 2024 +0700 +++ b/semicongine/platform/windows/window.nim Wed Apr 03 19:53:20 2024 +0700 @@ -64,11 +64,11 @@ proc createWindow*(title: string): NativeWindow = - # when DEBUG: - # AllocConsole() - # discard stdin.reopen("conIN$", fmRead) - # discard stdout.reopen("conOUT$", fmWrite) - # discard stderr.reopen("conOUT$", fmWrite) + when DEBUG: + AllocConsole() + discard stdin.reopen("conIN$", fmRead) + discard stdout.reopen("conOUT$", fmWrite) + discard stderr.reopen("conOUT$", fmWrite) result.hInstance = HINSTANCE(GetModuleHandle(nil)) var @@ -100,7 +100,7 @@ result.g_wpPrev.length = UINT(sizeof(WINDOWPLACEMENT)) discard result.hwnd.ShowWindow(SW_SHOW) -proc setTitle*(window: NativeWindow, title: string) +proc setTitle*(window: NativeWindow, title: string) = window.hwnd.SetWindowText(T(title)) # inspired by the one and only, Raymond Chen