[Telepathy] Issue in setting up text chat

ved kpl ved.kpl at gmail.com
Mon Sep 20 01:09:24 PDT 2010


Hi,

I have modified the
http://telepathy.freedesktop.org/doc/book/appendix.source-code.glib_get_roster.example.c.html
source code to support text chat.

I have basically hooked up a function with the main loop , which will
start the chat with one of the
contacts, once all the contacts have been loaded. The function is:

static gboolean
start_chat (gpointer data)
{
  TpContact* contact = (TpContact*) data;

  GHashTable* request = tp_asv_new (
      TP_IFACE_CHANNEL ".ChannelType",
      G_TYPE_STRING, TP_IFACE_CHANNEL_TYPE_TEXT,
      TP_IFACE_CHANNEL ".TargetHandleType",
      G_TYPE_UINT, TP_HANDLE_TYPE_CONTACT,
      TP_IFACE_CHANNEL ".TargetHandle",
      G_TYPE_UINT, tp_contact_get_handle (contact),
      TP_IFACE_CHANNEL ".TargetID",
      G_TYPE_STRING, tp_contact_get_identifier (contact),
      NULL);

  tp_cli_connection_interface_requests_call_ensure_channel (
      conn, -1, request, NULL, NULL, NULL, NULL);

  return FALSE;
}

The issue is, new_channels_cb() is not getting called after this. Can
anybody please help?
Am I missing anything here?

Regards,
Vikram


More information about the telepathy mailing list