Home > Software engineering >  MFC how to make the main window and a single child window using two different message loop
MFC how to make the main window and a single child window using two different message loop

Time:10-05

Sometimes I think child window message processing function block, but cannot affect the message response of the main interface, so it takes two to make a message loop, and each other, could you tell me how to achieve you greatly, I can't use CWinThread realize now, there is no other way can be achieved, and I used the wrong way,

CodePudding user response:

Child window of the message processing function block, sometimes can't solve with thread or the timer block

CodePudding user response:

Mainly is to make a separate dialog box processing and the main dialog box, I try to use CWinThread implements, but the dialog box can only specify the parent window for the desktop, so management up too difficult

CodePudding user response:

What is your child window? Modal dialog box?

CodePudding user response:

The
reference 3 floor VisualEleven response:
what is your child window? Modal dialog box?

My dialog is child dialogs, modeless

CodePudding user response:

Multiple Threads in the User Interface of http://msdn.microsoft.com/zh-cn/library/ms810439.aspx

CodePudding user response:

Message loop belongs to the thread, the concept of threads blocked is
The newly created thread to create forms, such news cycle will not interfere with each other

CodePudding user response:

refer to 6th floor zzz3265 response:
message loop belongs to the thread, the concept of threads blocked is
The newly created thread to create forms, such news cycle will not interfere with each other

I test phenomenon is not the case, if the window, created in the thread in the window of a function directly use the while loop, main interface there will be no response

CodePudding user response:

reference 5 floor zhao4zhong1 reply:
Multiple Threads in the User Interface of http://msdn.microsoft.com/zh-cn/library/ms810439.aspx

Please forgive me, I don't know much about the English level is not very good, you to explain bai, specific how to use

CodePudding user response:

refer to the eighth floor tianshi158366 response:
Quote: refer to the fifth floor zhao4zhong1 reply:

Multiple Threads in the User Interface of http://msdn.microsoft.com/zh-cn/library/ms810439.aspx

Please forgive me, I don't know much about the English level is not very good, you to explain bai, specific how to use


English is also a computer language,

http://fanyi.baidu.com/#en/zh/is hopeless and baidu translation to help you,

CodePudding user response:

Their search MFC version of intrinsic ProcessMessage, into the circulation inside,
  • Related