[WINAPI] Window in D
Daniel Wojdak
danielwojdak at gmail.com
Thu Jan 1 08:34:42 PST 2009
My english is not good. Apologize for this.
I start programming in D and i have a problem.
When I try make a window procedure and register class window. Compiler show error:
"Error: cannot implicitly convert expression (& WindowProcedure) of type intWindows function(HANDLE, uint, uint, int) function(HANDLE hwnd, uint message, uint wParam, int lParam) to intWindows function(HANDLE, uint, uint, int)"
Window Procedure:
"WNDPROC WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
{
switch (message)
{
case WM_DESTROY:
PostQuitMessage (0);
break;
default:
return cast(WNDPROC) DefWindowProcA (hwnd, message, wParam, lParam);
}
return cast(WNDPROC) 0;
}"
How must look window procedure in order to it's work?
More information about the Digitalmars-d-dtl
mailing list