JanE wrote:

> why does the add_timeout work even when i move windows 
> around and the add_fd methos blocks?

No idea. As Ian wrote already, I'd also think that
both should work the same way - from FLTK's point of
view.

Maybe the underlying system behaves differently. If this
is the case, then you may get different results, whatever
method you use.

> do you have any other ideas on how i could get a 
> nonblocking fd_add cb on the mac to "signal" my main 
> thread?

When I had a similar (but different, because of a
client-server architecture) problem, I decided to use
a TCP socket. This seemed to be the only way to make
it platform-independent (without #if...), because sockets
are supported in add_fd() for all platforms (incl. Windows).

> since, on windows, pipes are not supported

you mean: for usage with add_fd()? Otherwise see Ian's
reply.

> would you 
> recommend to use add_handler and call
> SendMessage(ui, some_unrecognized_event, 0, 0) from the 
> worker?

... or PostMessage or PostThreadMessage or ...

I'm far from a recommendation, but: yes, this may be a
way to do it with Windows. I'm just analyzing a problem,
where I might use such a mechanism, but I don't have the
code yet.

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

Reply via email to