quote:Original post by Endurion
Some messages are sent internally by DefWindowProc and you wont see them in the message pump.
One way to get a WM_CLOSE is when the user clicks the X on the top right corner. In the pump you'll see only (guessing here: WM_NCLBUTTONDOWN/UP) which DefWindowProc will translate to WM_CLOSE and if that's not handled by you followed by WM_DESTROY and so on...
Oh... that explains it!
EDIT: OK, I don't expect any more replies now, but the message parameter of WndProc is WM_CLOSE, so it has its message identifier after it is "dispatched", while in WndProc, but outside of it. And, like I said, the LOWORD macro doesn't work. I think I have a way around this, though, but it is pretty messy.
[edited by - PlayGGY on November 30, 2003 1:00:49 PM]
[edited by - PlayGGY on November 30, 2003 3:43:50 PM]