Example #1
0
void add_item_to_config_liststore(gpointer cdialog, gpointer inf, gpointer user_data)
{
    GtkListStore *list_store = (GtkListStore *)user_data;
    config_item_info_t *info = (config_item_info_t *)inf;

    VERB1 log("adding '%s' to workflow list\n", ci_get_screen_name(info));
    char *label;
    if (ci_get_screen_name(info) != NULL && ci_get_description(info) != NULL)
        label = xasprintf("<b>%s</b>\n%s",ci_get_screen_name(info), ci_get_description(info));
    else
        //if event has no xml description
        label = xasprintf("<b>%s</b>\n%s", _("No description available"), ci_get_name(info));

    GtkTreeIter iter;
    gtk_list_store_append(list_store, &iter);
    gtk_list_store_set(list_store, &iter,
                      COLUMN_UINAME, label,
                      COLUMN_NAME, ci_get_name(info),
                      CONFIG_DIALOG, cdialog,
                      -1);
    free(label);
}
Example #2
0
const char *wf_get_screen_name(workflow_t *w)
{
    return ci_get_screen_name(workflow_get_config_info(w));
}