How do I aviod MessageManagerLock w. more threads?


#1

I have more threads running that all needs to update the UI. When one of the threads sends something to the UI, JUCE pops up saying that I must use MessageManagerLock. I have done that now and it works nearly OK, but locking the Message Manager has some unwanted side effects.

How can I avoid using MessageManagerLock ? Is there another method by means of which I can write to/update the UI from more tasks ?

Thanks in advance

Eigil


#2

The only really safe way is to post a message that has the desired effect. Or you could use asyncupdater, actionlisteners, timers, etc to do this indirectly.


#3