switch (pMsg->MsgId) { case WM_CREATE: ... break; case WM_PAINT: ... break; case WM_SIZE: ... break; default: _Callback(pMsg); }