How exactly do Windows decide to return SendMessage, that is, how does it decide that the receiving stream has finished processing the sent message?
Detailed scenario: I have thread A using SendMessage to send a thread to thread B. Obviously, SendMessage does not return until thread B has finished processing the message. A dialog box appears in stream B and message transfer starts. In my script, there is a WM_KILLFOCUS message in the queue, which is pumped by stream B. This is the result of the WM_COMMAND message in stream B. Thread B passes this WM_COMMAND message to the default window. When this happens, SendMessage will return to thread A, although the original message has not finished processing! What's happening? By default, the proc window seems to obfuscate the windows, thinking that the original sent message was complete.
So, are there any well-known scenarios in which forwarding messages and invoking a window window by default can return SendMessage?
Thanks! Phil
phil
source share