diff options
author | Jonathan Blandford <jrb@redhat.com> | 2002-04-15 22:21:30 +0000 |
---|---|---|
committer | Jonathan Blandford <jrb@src.gnome.org> | 2002-04-15 22:21:30 +0000 |
commit | 3e88641895f1b84db2a8f76638da37ba67dc77fd (patch) | |
tree | 20ff039afe52ee0b90ace71388d597a997005765 /gtk/gtkcontainer.c | |
parent | cebcf77865438337aefd1fed85b2b3e184deed7c (diff) | |
download | gtk+-3e88641895f1b84db2a8f76638da37ba67dc77fd.tar.gz |
include internal children when doing focus.
Mon Apr 15 15:41:56 2002 Jonathan Blandford <jrb@redhat.com>
* gtk/gtkcontainer.c (gtk_container_focus): include internal
children when doing focus.
(gtk_container_get_all_children): new static function to include
internal children when making a list of them.
Diffstat (limited to 'gtk/gtkcontainer.c')
-rw-r--r-- | gtk/gtkcontainer.c | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/gtk/gtkcontainer.c b/gtk/gtkcontainer.c index b9aeea334e..b93d9d1ad6 100644 --- a/gtk/gtkcontainer.c +++ b/gtk/gtkcontainer.c @@ -1389,6 +1389,20 @@ get_focus_chain (GtkContainer *container) return g_object_get_data (G_OBJECT (container), "gtk-container-focus-chain"); } +/* same as gtk_container_get_children, except it includes internals + */ +static GList * +gtk_container_get_all_children (GtkContainer *container) +{ + GList *children = NULL; + + gtk_container_forall (container, + gtk_container_children_callback, + &children); + + return children; +} + static gboolean gtk_container_focus (GtkWidget *widget, GtkDirectionType direction) @@ -1420,7 +1434,7 @@ gtk_container_focus (GtkWidget *widget, if (container->has_focus_chain) children = g_list_copy (get_focus_chain (container)); else - children = gtk_container_get_children (container); + children = gtk_container_get_all_children (container); if (container->has_focus_chain && (direction == GTK_DIR_TAB_FORWARD || |