Hello, John Labenski <[EMAIL PROTECTED]> writes:
> I haven't tried to do any multithreading. I've seen of the lua mailing > list that coroutines are always suggested as an alternative. > > There is one catch though, any GUI function calls you make MUST be > made from the main thread. This is a limitation of the underlying GUI > system and not wxLua or wxWidgets. You use wxPostEvent to pass > messages from your thread to the main thread and then take action from Thanks for the reply. I have no much experience with coroutines, but it seems to me that it works well when you have a loop that executes always (and fast) the same code, like: while true do cycle() coroutine.yield() end And you have something like a timer to call coroutine.resume(). In my case I'm building a gui to an existing text application, I can't figure out a solution with coroutines different from putting yield's in arbritary lines of code. And that's why I think threads would be appropriate. Maybe I'm wrong? Thanks, Francisco ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ wxlua-users mailing list wxlua-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wxlua-users