comparison src/metadata.c @ 1457:5c0ecb2ebbc5

simplified code
author nadvornik
date Tue, 17 Mar 2009 19:09:34 +0000
parents b24391991f7f
children e015b6573d36
comparison
equal deleted inserted replaced
1456:b24391991f7f 1457:5c0ecb2ebbc5
1045 if (!gtk_tree_model_iter_children(keyword_tree, &iter, parent)) 1045 if (!gtk_tree_model_iter_children(keyword_tree, &iter, parent))
1046 return TRUE; /* this should happen only on empty helpers */ 1046 return TRUE; /* this should happen only on empty helpers */
1047 1047
1048 while (TRUE) 1048 while (TRUE)
1049 { 1049 {
1050 if (keyword_get_is_keyword(keyword_tree, &iter)) 1050 if (keyword_tree_is_set(keyword_tree, &iter, kw_list)) return FALSE;
1051 { 1051 if (!gtk_tree_model_iter_next(keyword_tree, &iter)) return TRUE;
1052 if (keyword_tree_is_set(keyword_tree, &iter, kw_list)) return FALSE;
1053 }
1054 else
1055 {
1056 /* for helpers we have to check recursively */
1057 if (!keyword_tree_check_empty_children(keyword_tree, &iter, kw_list)) return FALSE;
1058 }
1059
1060 if (!gtk_tree_model_iter_next(keyword_tree, &iter))
1061 {
1062 return TRUE;
1063 }
1064 } 1052 }
1065 } 1053 }
1066 1054
1067 void keyword_tree_reset(GtkTreeModel *keyword_tree, GtkTreeIter *iter_ptr, GList **kw_list) 1055 void keyword_tree_reset(GtkTreeModel *keyword_tree, GtkTreeIter *iter_ptr, GList **kw_list)
1068 { 1056 {