Home > Software engineering >  MFC interface card death problem, use the thread
MFC interface card death problem, use the thread

Time:09-28

With the thread of the t (func, xx); To perform a more time-consuming operation, the classification of the caffe operation,
Step through find logic no problem, step by step can be executed correctly, but when the execution interface will be stuck,

CodePudding user response:

A background thread, not to direct manipulation interface, but send a message to interface

CodePudding user response:

On code, so who also don't know what's the problem

CodePudding user response:

Background thread appropriate to add Sleep (0) switch threads

CodePudding user response:

The
reference 1/f, HDT response:
background threads, not direct manipulation interface, but send a message to interface

No user interface, interface I nothing at all

CodePudding user response:

reference zgl7903 reply: 3/f
background thread appropriate to add Sleep (0) switch threads
Sleep with no effect

CodePudding user response:

Contact me, help you debug the

CodePudding user response:

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

CodePudding user response:

The thread with the interface interaction PostMessage way as far as possible

CodePudding user response:

CodePudding user response:

Threads with interface interaction with sending a message

CodePudding user response:

Post code, just good analysis.
Interface card, one hundred percent did time-consuming operation in the UI thread, or something else blocking the UI thread's message loop.

CodePudding user response:

Thread does not generally card interface, you must be doing something blocking the main thread, to interface to the Lord, or code, or a good check,

CodePudding user response:

You should be a widget to refresh, caused the jam, I also met before, step through no problem, perform felt no, blocked,

CodePudding user response:

The thread has infinite loop
  • Related