[Prev][Next][Index][Thread]

Re: DUIM event queue



Dustin Voss wrote in message ...
>Is there something I'm missing, or is there no function to get the next
>event from the event queue?  How can one write an event loop
>independently of the main event loop?

'with-pointer-grabbed' redirects the event stream to the sheet
that grabbed the pointer.  All you need to do is handle the event
stream that comes in on that sheet by writing 'handle-event'
methods.  Deuce does this for its auto-scrolling.  Look at
deuce/duim/events.dylan to see how Deuce does it.

If you think you must monitor the event queue directly (and I don't
think you do), you can import the event queue bindings from
the 'duim-sheets-internals' module.  For the details of how it
works, read duim/sheets/event-queue.dylan and events.dylan.

Don't feel too guilty about using duim-sheets-internals.  All the
duim-xxx-internals modules in DUIM are for people who want
to extend DUIM, rather than be "mere clients".  These interfaces
are more open to change than the non-internals modules, but
DUIM is pretty mature and stable.





References: