i'm learning win32 from: http://www.winprog.org/tutorial/start.html
but tell me(because i ear several persons) is these function correct?
LRESULT CALLBACK WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
switch(msg)
{
case WM_CLOSE:
DestroyWindow(hwnd);
break;
case WM_DESTROY:
PostQuitMessage(0);
break;
default:
return DefWindowProc(hwnd, msg, wParam, lParam);
}
return 0;
}
the DefWindowProc() is on right place or must be outside of switch?
pleace anyone correct me