Function
CMCallback
Declaration
void
(* CmCallback) (
  CmClient* self,
  CmRoom* room,
  GPtrArray* events,
  GError* err,
  gpointer user_data
)
Description [src]
Type definition for the function that will be called when the client sees new events.
Usually you don’t do much in this callback. The items-changed
signals of the list models returned from
e.g. cm_client_get_joined_rooms() or cm_room_get_events_list()
are easier to use.
The GMainContext for these operations isn’t well defined atm, see https://source.puri.sm/Librem5/libcmatrix/-/issues/24.
Parameters
- self
- 
            Type: CmClientThe client that received the events. The data is owned by the caller of the function. 
- room
- 
            Type: CmRoomThe room (if any) the events belong to. The argument can be NULL.The data is owned by the caller of the function. 
- events
- 
            Type: An array of NoneThe events. The data is owned by the caller of the function. 
- err
- 
            Type: GErrorA recoverable error. The argument can be NULL.The data is owned by the caller of the function. 
- user_data
- 
            Type: gpointerThe user data passed in cm_client_set_sync_callback().The argument can be NULL.The data is owned by the caller of the function.