Create dialog window using CreateWindowEx16/W depending on template type, not dialog procedure type.
diff --git a/windows/dialog.c b/windows/dialog.c index f2adb71..92da06f 100644 --- a/windows/dialog.c +++ b/windows/dialog.c
@@ -688,8 +688,7 @@ if ((INT16)template.x == CW_USEDEFAULT16) { - rect.left = rect.top = (procType == WIN_PROC_16) ? CW_USEDEFAULT16 - : CW_USEDEFAULT; + rect.left = rect.top = win32Template? CW_USEDEFAULT : CW_USEDEFAULT16; } else { @@ -721,7 +720,7 @@ } } - if (procType == WIN_PROC_16) + if (!win32Template) hwnd = CreateWindowEx16(template.exStyle, template.className, template.caption, template.style & ~WS_VISIBLE, rect.left, rect.top, rect.right, rect.bottom,