[Xcb] magical callback funness

Henrik Sandklef hesa at sandklef.com
Thu Mar 24 08:25:52 PST 2005

> I've run into a snag with record.  It there's a request/reply called
> RecordGetContext.  This gets the events recorded on the current
> connection.

When working with RECORD you use a context type. When having made one such
you can:

 1 Query the state
  Done using the function XRecordGetContext

  The request "RecordGetContext" is sent after the
  function XRecordGetContext has been called

  2 Start/stop recording
  Done using the function XRecordEnableContext/XRecordDisableContext

  The request RecordEnableContext is sent after the
  function XRecordEnableContext has been called

  The request RecordDisableContext is sent after the
  function XRecordDisableContext has been called

> However when calling the reply it enters a loop and prints
> out how no record was found for such and such an event.

Calling the reply? Can you please give some more info? Do you mean sending?

Can you show me your source code?

>  The problem is
> that I can't get out of this loop to do other things like parse the
> information and what not.

Where is your code located? In the client or the server?

> Xlib seems to solve this problem by installing a callback (I'm not
> really sure how it works though). when enabling the context
> (RecordEnableContext).
This is right.

> I'm not sure how to solve this.  Ideas, suggestions?
Show the sources :)


More information about the xcb mailing list