mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-19 15:18:55 +02:00
Add G_TRAVERSE_LEAVES and G_TRAVERSE_NON_LEAVES as alternative names for
2004-11-08 Matthias Clasen <mclasen@redhat.com> * glib/gnode.h (enum GTraverseFlags): Add G_TRAVERSE_LEAVES and G_TRAVERSE_NON_LEAVES as alternative names for G_TRAVERSE_LEAFS and G_TRAVERSE_NON_LEAFS, which are grammatically brutal. (#138853, Morten Welinder)
This commit is contained in:
committed by
Matthias Clasen
parent
c915c2d683
commit
a84cbafcec
@@ -9,6 +9,11 @@ Mon Nov 8 10:45:50 2004 Manish Singh <yosh@gimp.org>
|
|||||||
|
|
||||||
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* glib/gnode.h (enum GTraverseFlags): Add G_TRAVERSE_LEAVES
|
||||||
|
and G_TRAVERSE_NON_LEAVES as alternative names for
|
||||||
|
G_TRAVERSE_LEAFS and G_TRAVERSE_NON_LEAFS, which are
|
||||||
|
grammatically brutal. (#138853, Morten Welinder)
|
||||||
|
|
||||||
* glib/gasyncqueue.[hc]:
|
* glib/gasyncqueue.[hc]:
|
||||||
* glib/ghook.[hc]:
|
* glib/ghook.[hc]:
|
||||||
* glib/gmain.[hc]:
|
* glib/gmain.[hc]:
|
||||||
|
@@ -9,6 +9,11 @@ Mon Nov 8 10:45:50 2004 Manish Singh <yosh@gimp.org>
|
|||||||
|
|
||||||
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* glib/gnode.h (enum GTraverseFlags): Add G_TRAVERSE_LEAVES
|
||||||
|
and G_TRAVERSE_NON_LEAVES as alternative names for
|
||||||
|
G_TRAVERSE_LEAFS and G_TRAVERSE_NON_LEAFS, which are
|
||||||
|
grammatically brutal. (#138853, Morten Welinder)
|
||||||
|
|
||||||
* glib/gasyncqueue.[hc]:
|
* glib/gasyncqueue.[hc]:
|
||||||
* glib/ghook.[hc]:
|
* glib/ghook.[hc]:
|
||||||
* glib/gmain.[hc]:
|
* glib/gmain.[hc]:
|
||||||
|
@@ -9,6 +9,11 @@ Mon Nov 8 10:45:50 2004 Manish Singh <yosh@gimp.org>
|
|||||||
|
|
||||||
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* glib/gnode.h (enum GTraverseFlags): Add G_TRAVERSE_LEAVES
|
||||||
|
and G_TRAVERSE_NON_LEAVES as alternative names for
|
||||||
|
G_TRAVERSE_LEAFS and G_TRAVERSE_NON_LEAFS, which are
|
||||||
|
grammatically brutal. (#138853, Morten Welinder)
|
||||||
|
|
||||||
* glib/gasyncqueue.[hc]:
|
* glib/gasyncqueue.[hc]:
|
||||||
* glib/ghook.[hc]:
|
* glib/ghook.[hc]:
|
||||||
* glib/gmain.[hc]:
|
* glib/gmain.[hc]:
|
||||||
|
@@ -9,6 +9,11 @@ Mon Nov 8 10:45:50 2004 Manish Singh <yosh@gimp.org>
|
|||||||
|
|
||||||
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* glib/gnode.h (enum GTraverseFlags): Add G_TRAVERSE_LEAVES
|
||||||
|
and G_TRAVERSE_NON_LEAVES as alternative names for
|
||||||
|
G_TRAVERSE_LEAFS and G_TRAVERSE_NON_LEAFS, which are
|
||||||
|
grammatically brutal. (#138853, Morten Welinder)
|
||||||
|
|
||||||
* glib/gasyncqueue.[hc]:
|
* glib/gasyncqueue.[hc]:
|
||||||
* glib/ghook.[hc]:
|
* glib/ghook.[hc]:
|
||||||
* glib/gmain.[hc]:
|
* glib/gmain.[hc]:
|
||||||
|
@@ -9,6 +9,11 @@ Mon Nov 8 10:45:50 2004 Manish Singh <yosh@gimp.org>
|
|||||||
|
|
||||||
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* glib/gnode.h (enum GTraverseFlags): Add G_TRAVERSE_LEAVES
|
||||||
|
and G_TRAVERSE_NON_LEAVES as alternative names for
|
||||||
|
G_TRAVERSE_LEAFS and G_TRAVERSE_NON_LEAFS, which are
|
||||||
|
grammatically brutal. (#138853, Morten Welinder)
|
||||||
|
|
||||||
* glib/gasyncqueue.[hc]:
|
* glib/gasyncqueue.[hc]:
|
||||||
* glib/ghook.[hc]:
|
* glib/ghook.[hc]:
|
||||||
* glib/gmain.[hc]:
|
* glib/gmain.[hc]:
|
||||||
|
@@ -1,5 +1,8 @@
|
|||||||
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
2004-11-08 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* glib/tmpl/trees-nary.sgml: Document G_TRAVERSE_LEAVES and
|
||||||
|
G_TRAVERSE_NON_LEAVES
|
||||||
|
|
||||||
* glib/tmpl/hooks.sgml:
|
* glib/tmpl/hooks.sgml:
|
||||||
* glib/tmpl/iochannels.sgml: Updates
|
* glib/tmpl/iochannels.sgml: Updates
|
||||||
|
|
||||||
|
@@ -232,7 +232,7 @@ The traversal can be halted at any point by returning %TRUE from @func.
|
|||||||
@order: the order in which nodes are visited - %G_IN_ORDER, %G_PRE_ORDER,
|
@order: the order in which nodes are visited - %G_IN_ORDER, %G_PRE_ORDER,
|
||||||
%G_POST_ORDER, or %G_LEVEL_ORDER.
|
%G_POST_ORDER, or %G_LEVEL_ORDER.
|
||||||
@flags: which types of children are to be visited, one of %G_TRAVERSE_ALL,
|
@flags: which types of children are to be visited, one of %G_TRAVERSE_ALL,
|
||||||
%G_TRAVERSE_LEAFS and %G_TRAVERSE_NON_LEAFS.
|
%G_TRAVERSE_LEAVES and %G_TRAVERSE_NON_LEAVES.
|
||||||
@max_depth: the maximum depth of the traversal. Nodes below this
|
@max_depth: the maximum depth of the traversal. Nodes below this
|
||||||
depth will not be visited. If max_depth is -1 all nodes in the tree are
|
depth will not be visited. If max_depth is -1 all nodes in the tree are
|
||||||
visited. If depth is 1, only the root is visited. If depth is 2, the root
|
visited. If depth is 1, only the root is visited. If depth is 2, the root
|
||||||
@@ -247,10 +247,14 @@ Specifies which nodes are visited during several of the tree functions,
|
|||||||
including g_node_traverse() and g_node_find().
|
including g_node_traverse() and g_node_find().
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@G_TRAVERSE_LEAFS: only leaf nodes should be visited.
|
@G_TRAVERSE_LEAVES: only leaf nodes should be visited. This name has been
|
||||||
@G_TRAVERSE_NON_LEAFS: only non-leaf nodes should be visited.
|
introduced in 2.6, for older version use %G_TRAVERSE_LEAFS.
|
||||||
|
@G_TRAVERSE_NON_LEAVES: only non-leaf nodes should be visited. This name
|
||||||
|
has been introduced in 2.6, for older version use %G_TRAVERSE_NON_LEAFS.
|
||||||
@G_TRAVERSE_ALL: all nodes should be visited.
|
@G_TRAVERSE_ALL: all nodes should be visited.
|
||||||
@G_TRAVERSE_MASK:
|
@G_TRAVERSE_MASK:
|
||||||
|
@G_TRAVERSE_LEAFS: identical to %G_TRAVERSE_LEAVES
|
||||||
|
@G_TRAVERSE_NON_LEAFS: identical to %G_TRAVERSE_NON_LEAVES
|
||||||
|
|
||||||
<!-- ##### USER_FUNCTION GNodeTraverseFunc ##### -->
|
<!-- ##### USER_FUNCTION GNodeTraverseFunc ##### -->
|
||||||
<para>
|
<para>
|
||||||
@@ -273,7 +277,7 @@ Note that it doesn't descend beneath the child nodes.
|
|||||||
|
|
||||||
@node: a #GNode.
|
@node: a #GNode.
|
||||||
@flags: which types of children are to be visited, one of %G_TRAVERSE_ALL,
|
@flags: which types of children are to be visited, one of %G_TRAVERSE_ALL,
|
||||||
%G_TRAVERSE_LEAFS and %G_TRAVERSE_NON_LEAFS.
|
%G_TRAVERSE_LEAVES and %G_TRAVERSE_NON_LEAVES.
|
||||||
@func: the function to call for each visited node.
|
@func: the function to call for each visited node.
|
||||||
@data: user data to pass to the function.
|
@data: user data to pass to the function.
|
||||||
|
|
||||||
@@ -307,7 +311,7 @@ Finds a #GNode in a tree.
|
|||||||
@order: the order in which nodes are visited - %G_IN_ORDER, %G_PRE_ORDER,
|
@order: the order in which nodes are visited - %G_IN_ORDER, %G_PRE_ORDER,
|
||||||
%G_POST_ORDER, or %G_LEVEL_ORDER.
|
%G_POST_ORDER, or %G_LEVEL_ORDER.
|
||||||
@flags: which types of children are to be searched, one of %G_TRAVERSE_ALL,
|
@flags: which types of children are to be searched, one of %G_TRAVERSE_ALL,
|
||||||
%G_TRAVERSE_LEAFS and %G_TRAVERSE_NON_LEAFS.
|
%G_TRAVERSE_LEAVES and %G_TRAVERSE_NON_LEAVES.
|
||||||
@data: the data to find.
|
@data: the data to find.
|
||||||
@Returns: the found #GNode, or %NULL if the data is not found.
|
@Returns: the found #GNode, or %NULL if the data is not found.
|
||||||
|
|
||||||
@@ -319,7 +323,7 @@ Finds the first child of a #GNode with the given data.
|
|||||||
|
|
||||||
@node: a #GNode.
|
@node: a #GNode.
|
||||||
@flags: which types of children are to be searched, one of %G_TRAVERSE_ALL,
|
@flags: which types of children are to be searched, one of %G_TRAVERSE_ALL,
|
||||||
%G_TRAVERSE_LEAFS and %G_TRAVERSE_NON_LEAFS.
|
%G_TRAVERSE_LEAVES and %G_TRAVERSE_NON_LEAVES.
|
||||||
@data: the data to find.
|
@data: the data to find.
|
||||||
@Returns: the found child #GNode, or %NULL if the data is not found.
|
@Returns: the found child #GNode, or %NULL if the data is not found.
|
||||||
|
|
||||||
@@ -454,7 +458,7 @@ Gets the number of nodes in a tree.
|
|||||||
|
|
||||||
@root: a #GNode.
|
@root: a #GNode.
|
||||||
@flags: which types of children are to be counted, one of %G_TRAVERSE_ALL,
|
@flags: which types of children are to be counted, one of %G_TRAVERSE_ALL,
|
||||||
%G_TRAVERSE_LEAFS and %G_TRAVERSE_NON_LEAFS.
|
%G_TRAVERSE_LEAVES and %G_TRAVERSE_NON_LEAVES.
|
||||||
@Returns: the number of nodes in the tree.
|
@Returns: the number of nodes in the tree.
|
||||||
|
|
||||||
|
|
||||||
|
10
glib/gnode.h
10
glib/gnode.h
@@ -36,10 +36,12 @@ typedef struct _GNode GNode;
|
|||||||
/* Tree traverse flags */
|
/* Tree traverse flags */
|
||||||
typedef enum
|
typedef enum
|
||||||
{
|
{
|
||||||
G_TRAVERSE_LEAFS = 1 << 0,
|
G_TRAVERSE_LEAVES = 1 << 0,
|
||||||
G_TRAVERSE_NON_LEAFS = 1 << 1,
|
G_TRAVERSE_NON_LEAVES = 1 << 1,
|
||||||
G_TRAVERSE_ALL = G_TRAVERSE_LEAFS | G_TRAVERSE_NON_LEAFS,
|
G_TRAVERSE_ALL = G_TRAVERSE_LEAVES | G_TRAVERSE_NON_LEAVES,
|
||||||
G_TRAVERSE_MASK = 0x03
|
G_TRAVERSE_MASK = 0x03,
|
||||||
|
G_TRAVERSE_LEAFS = G_TRAVERSE_LEAVES,
|
||||||
|
G_TRAVERSE_NON_LEAFS = G_TRAVERSE_NON_LEAVES
|
||||||
} GTraverseFlags;
|
} GTraverseFlags;
|
||||||
|
|
||||||
/* Tree traverse orders */
|
/* Tree traverse orders */
|
||||||
|
Reference in New Issue
Block a user