If i have a function in a thread that is processing some data, then it calls a callback function to update the status in the UI.
If the UI takes time to process the callback function then it is not so much usefull. Instead of just handling the update in the callback function, should it send some kind of message to the UI that way it doesnt block?
I mean when in the processing function and i call the update status function, this should return immediately to the procesing function, then in the update it can wait all it wants for the UI update to finish.
Or do I need a 3rd thread to handle the sending update data to the UI ?