New public function to find a row by its data pointer using a custom

1998-08-03  Federico Mena Quintero  <federico@nuclecu.unam.mx>

	* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
	function to find a row by its data pointer using a custom
	comparison function.
This commit is contained in:
Federico Mena Quintero 1998-08-03 19:50:23 +00:00 committed by Arturo Espinosa
parent 08d246be89
commit f8a40e214a
9 changed files with 67 additions and 0 deletions

View File

@ -1,3 +1,9 @@
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
function to find a row by its data pointer using a custom
comparison function.
Sun Aug 02 22:58:00 1998 George Lebl <jirka@5z.com>
* gtk/gtkclist.c: draw the buttons during a "draw" as well,

View File

@ -1,3 +1,9 @@
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
function to find a row by its data pointer using a custom
comparison function.
Sun Aug 02 22:58:00 1998 George Lebl <jirka@5z.com>
* gtk/gtkclist.c: draw the buttons during a "draw" as well,

View File

@ -1,3 +1,9 @@
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
function to find a row by its data pointer using a custom
comparison function.
Sun Aug 02 22:58:00 1998 George Lebl <jirka@5z.com>
* gtk/gtkclist.c: draw the buttons during a "draw" as well,

View File

@ -1,3 +1,9 @@
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
function to find a row by its data pointer using a custom
comparison function.
Sun Aug 02 22:58:00 1998 George Lebl <jirka@5z.com>
* gtk/gtkclist.c: draw the buttons during a "draw" as well,

View File

@ -1,3 +1,9 @@
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
function to find a row by its data pointer using a custom
comparison function.
Sun Aug 02 22:58:00 1998 George Lebl <jirka@5z.com>
* gtk/gtkclist.c: draw the buttons during a "draw" as well,

View File

@ -1,3 +1,9 @@
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
function to find a row by its data pointer using a custom
comparison function.
Sun Aug 02 22:58:00 1998 George Lebl <jirka@5z.com>
* gtk/gtkclist.c: draw the buttons during a "draw" as well,

View File

@ -1,3 +1,9 @@
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
function to find a row by its data pointer using a custom
comparison function.
Sun Aug 02 22:58:00 1998 George Lebl <jirka@5z.com>
* gtk/gtkclist.c: draw the buttons during a "draw" as well,

View File

@ -4077,6 +4077,27 @@ gtk_ctree_find_by_row_data (GtkCTree *ctree,
return NULL;
}
GtkCTreeNode *
gtk_ctree_find_by_row_data_custom (GtkCTree *ctree,
GtkCTreeNode *node,
gpointer data,
GCompareFunc func)
{
GtkCTreeNode *work;
while (node)
{
if (!func (GTK_CTREE_ROW (node)->row.data, data))
return node;
if (GTK_CTREE_ROW (node)->children &&
(work = gtk_ctree_find_by_row_data_custom
(ctree, GTK_CTREE_ROW (node)->children, data, func)))
return work;
node = GTK_CTREE_ROW (node)->sibling;
}
return NULL;
}
gboolean
gtk_ctree_is_hot_spot (GtkCTree *ctree,
gint x,

View File

@ -222,6 +222,10 @@ gboolean gtk_ctree_is_ancestor (GtkCTree *ctree,
GtkCTreeNode * gtk_ctree_find_by_row_data (GtkCTree *ctree,
GtkCTreeNode *node,
gpointer data);
GtkCTreeNode * gtk_ctree_find_by_row_data_custom (GtkCTree *ctree,
GtkCTreeNode *node,
gpointer data,
GCompareFunc func);
gboolean gtk_ctree_is_hot_spot (GtkCTree *ctree,
gint x,
gint y);