From: Johan H. <ma...@ar...> - 2005-12-30 19:27:58
|
hello, for certain reasons I need to run several OS threads and now I need to pass some data to the GUI. I know that wxhaskell is not threadsafe but when I look at wxwindows docs I find the function wxEvtHandler::AddPendingEvent void AddPendingEvent(wxEvent& event) which seem to do what I want to. As it's below wxhaskell and actually made for this purpose, I don't see a major problem in using it. the question is, how do I call this function with wxhaskell? I don't see this function exported anywhere. It would be sufficient if I just could send an idle event (although a custom event would be better; whatever works) from the thread and then let an event handler in the GUI do the rest of the fiddling (this at least avoids polling). so, essentially, how do I call this? do anyone have some code I can cutnpaste from? I can't reasonably be the first one with this problem. Thanks, Johan Henriksson |