add_event (const char *bus_name, const char *event)
{
  event_data *evdata;
  gchar **data;

  spi_atk_add_client (bus_name);
  evdata = (event_data *) g_malloc (sizeof (*evdata));
  if (!evdata)
    return;
  data = g_strsplit (event, ":", 3);
  if (!data)
    {
      g_free (evdata);
      return;
    }
  evdata->bus_name = g_strdup (bus_name);
  evdata->data = data;
  spi_global_app_data->events = g_list_append (spi_global_app_data->events, evdata);
}
add_event (const char *bus_name, const char *event)
{
  event_data *evdata;
  gchar **data;

  spi_atk_add_client (bus_name);
  evdata = (event_data *) g_malloc (sizeof (*evdata));
  if (!evdata)
    return;
  data = g_strsplit (event, ":", 3);
  if (!data)
    {
      g_free (evdata);
      return;
    }
  evdata->bus_name = g_strdup (bus_name);
  evdata->data = data;
  spi_global_app_data->events = g_list_append (spi_global_app_data->events, evdata);
}