> Thanks for the quick reply.  I had to try a few things but 
> found a working combination.  All FLTK object are now created 
> in the main thread as well as the first call to "show" the 
> widgets and Fl::check() (or Fl::run).  The only thing the 
> separate thread does is:
>   Fl::lock();
>   ... update widget data
>   Fl::unlock();

That should be about right...


> Two things to note:
> - "Fl::awake" seems optional, at least on Mac OS and for what 
> I am doing.

Though you should not depend on that behaviour - it is almost certainly
a "side-effect" of other things your code is doing, I suspect.

> - My initial problem was that I was calling both "Fl::check" 
> AND "widget->show" in the separate thread.  On Mac OS, it 
> looks like both need to be in the main thread.

Indeed so, and on some WinXX versions, and (some) X11 WM combinations
too, it appears. I think this is advised in the docs...

Basically, if you want your code to be protable, aim for the lowest
common denominator!



SELEX Galileo Ltd
Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 
3EL
A company registered in England & Wales.  Company no. 02426132
********************************************************************
This email and any attachments are confidential to the intended
recipient and may also be privileged. If you are not the intended
recipient please delete it from your system and notify the sender.
You should not copy it or use it for any purpose nor disclose or
distribute its contents to any other person.
********************************************************************

_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to