When you create a new Win32 project in Visual C++ 2005, you get a message loop
that looks like this:
// Main message loop:
while (GetMessage(&msg, NULL, 0, 0))
{
if (!TranslateAccelerator(msg.hwnd, hAccelTable, &msg))
{
TranslateMessage(&msg);
DispatchMessage(&msg);
}
}
So what's wrong with that?