GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_QUESTION,
GTK_BUTTONS_YES_NO,
- "Are you sure you want to delete the selected key from database?");
+ "Are you sure you want to delete the selected key?");
if (gtk_dialog_run (GTK_DIALOG (diag)) == GTK_RESPONSE_YES)
{
ZakConfi *confi;
- GtkTreeIter iterConfig;
- gtk_tree_model_get_iter (GTK_TREE_MODEL (storeFolders), &iterConfig,
- gtk_tree_path_new_from_indices (gtk_tree_path_get_indices (path)[0], -1));
+ ZakConfiKey *ck;
- gtk_tree_model_get (GTK_TREE_MODEL (storeFolders), &iterConfig,
- -1);
+ ck = g_new0 (ZakConfiKey, 1);
- if (ZAK_IS_CONFI (confi))
- {
- ZakConfiKey *ck;
+ gtk_tree_model_get (GTK_TREE_MODEL (storeFolders), &iter,
+ FOLDERS_COL_CONFIG, &ck->config,
+ FOLDERS_COL_PATH, &ck->path,
+ FOLDERS_COL_KEY, &ck->key,
+ -1);
- gtk_tree_model_get (GTK_TREE_MODEL (storeFolders), &iter,
- -1);
+ confi = zak_confi_new (g_strdup_printf ("%s;CONFI_NAME=%s", cnc_string, ck->config));
+ if (confi != NULL)
+ {
if (zak_confi_remove_path (confi, g_strconcat (ck->path, "/", ck->key, NULL)))
{
gtk_tree_store_remove (storeFolders, &iter);