for(int i=0; i<2000; I++)
{
If (PeekMessage (& amp; MSG, NULL, 0, 0, PM_REMOVE))
{
TranslateMessage (& amp; MSG);
DispatchMessage (& amp; MSG);
}
}
Who knows what this code is used for
CodePudding user response:
PeekMessage retrieve messages from the message queue, if the retrieved a message, return true, according to the normal way to handle the message, if no news, return falseTranslateMessage (conversion) :
DispatchMessage (dispatch) :
Function understanding you will understand
CodePudding user response:
These three functions is a typical Windows window procedure message driven mechanism, the role of respectively from the literal can see out, detail, oneself look in the encyclopedia:http://baike.baidu.com/view/1080178.htm
http://baike.baidu.com/view/1013950.htm
http://baike.baidu.com/view/1013961.htm
CodePudding user response:
In CB, you is to use less than they,