Usually, the trick is to place the code that manipulates the UI in a 0 ms timer. If you need to pass variables, subclass the timer and add public properties to it.
We come a long way. When 64 bits builds come, we may even have multicore threading. Anything like the good’ol time slicing threading à la Real Basic is out of question.
[quote=146731:@Robert Dunn]“A thread has attempted to manipulate a user interface element. This can only be done from the application’s main thread.”
Is there no way to have a thread “manipulate a user interface element” ?
[/quote]
No
It’s never really been safe
No
Most UI toolkits (Cocoa, Windows, GTK) are not thread safe
This is a common problem in any language that uses UI - they deal with it in different ways
It was actually unsafe then as well.
But, in Carbon apps, the runtime was such that you would almost never see a problem - but they still could happen.