Dan Sugalski wrote:

> Gordon Henriksen wrote:
> 
> > So, for GUI events, could calling into parrot and doing the 
> > following from the OS event handler work to synchronously dispatch 
> > an event?
> >
> >     ... parrot-ify a mouse-moved event into $P5 ...
> >     post $P5
> >     checkevent
> >
> > Hm. No.
> 
> For that I think you'd want:
> 
>       post $P5
>       wait $P5

I suppose that would work, since the "wait" would block the main OS
thread. It does cause unnecessary context switches, though.

What happens in this case if the parrot eventloop is stopped? Does the
GUI thread block indefinitely in the "wait" op? That would keep the
program open even though parrot seemingly wanted to shut down.

Just decoupling the event queue and dispatch mechanisms seems cleaner to
my eye.

-- 

Gordon Henriksen
IT Manager
ICLUBcentral Inc.
[EMAIL PROTECTED]

Reply via email to