diff --git a/gui/model.c b/gui/model.c index f80aaa3f..c855508a 100644 --- a/gui/model.c +++ b/gui/model.c @@ -180,6 +180,13 @@ static gboolean _queue_model_iter_nth_child(GtkTreeModel *model, return __queue_model_iter_nth(GUI_QUEUE_MODEL(model), iter, n); } +static gboolean _queue_model_iter_parent(GtkTreeModel *model, + GtkTreeIter *iter, + GtkTreeIter *child) +{ + return FALSE; +} + static void _queue_model_init(GuiQueueModel *model) { model->gqm_stamp = g_random_int(); @@ -213,6 +220,7 @@ static void _queue_tree_model_init(GtkTreeModelIface *iface) iface->iter_has_child = _queue_model_iter_has_child; iface->iter_n_children = _queue_model_iter_n_children; iface->iter_nth_child = _queue_model_iter_nth_child; + iface->iter_parent = _queue_model_iter_parent; } diff --git a/tests/gui/model.c b/tests/gui/model.c index 49113574..214c2af5 100644 --- a/tests/gui/model.c +++ b/tests/gui/model.c @@ -93,6 +93,7 @@ static void test_empty() test_equal(gtk_tree_model_iter_n_children(model, &iter), 0); test_equal(gtk_tree_model_iter_n_children(model, NULL), 0); test_equal(gtk_tree_model_iter_nth_child(model, &iter, NULL, 3), false); + test_equal(gtk_tree_model_iter_parent(model, &iter, &iter), false); g_object_unref(model); } @@ -173,6 +174,8 @@ static void test_model() track = iter.user_data2; test_equal(track->tr_track, 4); + test_equal(gtk_tree_model_iter_parent(model, &iter, &iter), false); + g_object_unref(model); }