Those of you who have followed my questions know that my program deals a lot with multithreading. I don't think it will stop there either. I am downloading files...polling variables....connecting sockets and communication between processes. What I need more information on is managing all these threads. Specifically, how to make certain things a priority in my program. I need to know how I can give priority in the following order:
Main Thread (UI):
Trigger display messages thread(Polling For Incomming Messages):
What this means is that I want, above all, all UI messages processed first....then when there are no UI messages to process...I want the work to be divided evenly among the communications and displaying of messages. So if the user wants to do something with the program...it is available immediately...otherwise...it is recieving messages from the socket and the Trigger Display Messages Thread is polling for things to display and displaying them as fast as possible.
Can anyone tell me how to achieve that. A small explanation or a good reference would be great. The only thing I ask is to not give me pages of code to look through for the answer. I would love any help I could get with this. Thank everyone who has followed up on my questions for all the continuing help.