On 2 Jan 2013, at 13:30, claude roux wrote: > However, after reading your response, I came to realize that one specificity > of my implementation is that the FLTK main loop is launched within a thread, > which is usually OK for most things, except as it appears for the timeout > (and also as I have recently discovered for "awake", which is no longer > invoked if Fl::run is not in the main thread, which is pretty logical, > actually)...
Ah... Hm, well, I have to say I would recommend against that. It throws up some very strange and inconsistent behaviours across platforms. In particular, the behaviour on WinXX systems is quite inconsistent, and can vary a lot form windows version to version (I guess MS changed things internally as they went along - though later versions seem better than older ones, as a general handwave impression, i.e. Win7 is less flaky than WinXP if your run thongs from a child thread. Well, maybe...) Though, for what it is worth, I have a colleague who has a large and complex Windows-only app written in fltk that, due to the odd way it is initiated, in effect runs the fltk loop from a child thread (i.e. not the main() thread) and it does work OK. (Though I keep suggesting he change it, and perhaps he has done now!) In particular, though, he has seen episodes where the behaviour of the app is erratic on some machines and good on others (the suspicion is that the different graphics drivers may be behind this, though that is uncertain...) Anyway, I guess what I'm saying is that, if you really want to go this way, then test your code on as many *different* host machines with as many different graphics drivers and host OS versions as possible, as I suspect that even though it works fine one your dev machines it may not work for your end users! Just a word of caution... -- Ian _______________________________________________ fltk mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk

