2004-04-13 Matthias Clasen <mclasen@redhat.com>
+ * gtk/gtkuimanager.c (get_child_node): Don't crash if a node
+ has no name.
+ (start_element_handler): Accept separators without unique
+ names. (#133302, Anders Carlsson)
+
* gtk/gtkactiongroup.c (gtk_action_group_add_action): Document
possible accelerator gotcha when using this function. (#139641,
Christian Persch)
2004-04-13 Matthias Clasen <mclasen@redhat.com>
+ * gtk/gtkuimanager.c (get_child_node): Don't crash if a node
+ has no name.
+ (start_element_handler): Accept separators without unique
+ names. (#133302, Anders Carlsson)
+
* gtk/gtkactiongroup.c (gtk_action_group_add_action): Document
possible accelerator gotcha when using this function. (#139641,
Christian Persch)
2004-04-13 Matthias Clasen <mclasen@redhat.com>
+ * gtk/gtkuimanager.c (get_child_node): Don't crash if a node
+ has no name.
+ (start_element_handler): Accept separators without unique
+ names. (#133302, Anders Carlsson)
+
* gtk/gtkactiongroup.c (gtk_action_group_add_action): Document
possible accelerator gotcha when using this function. (#139641,
Christian Persch)
2004-04-13 Matthias Clasen <mclasen@redhat.com>
+ * gtk/gtkuimanager.c (get_child_node): Don't crash if a node
+ has no name.
+ (start_element_handler): Accept separators without unique
+ names. (#133302, Anders Carlsson)
+
* gtk/gtkactiongroup.c (gtk_action_group_add_action): Document
possible accelerator gotcha when using this function. (#139641,
Christian Persch)
2004-04-13 Matthias Clasen <mclasen@redhat.com>
+ * gtk/gtkuimanager.c (get_child_node): Don't crash if a node
+ has no name.
+ (start_element_handler): Accept separators without unique
+ names. (#133302, Anders Carlsson)
+
* gtk/gtkactiongroup.c (gtk_action_group_add_action): Document
possible accelerator gotcha when using this function. (#139641,
Christian Persch)
+2004-04-13 Matthias Clasen <mclasen@redhat.com>
+
+ * gtk/tmpl/gtkuimanager.sgml: Some corrections.
+
2004-04-13 Federico Mena Quintero <federico@ximian.com>
* gtk/tmpl/gtkfilechooser.sgml: Typo fix.
<!ATTLIST toolbar name #IMPLIED >
<!ATTLIST popup name #IMPLIED >
<!ATTLIST placeholder name #IMPLIED >
+<!ATTLIST separator name #IMPLIED >
<!ATTLIST menu name #IMPLIED
action #REQUIRED
position (top|bot) #IMPLIED >
of menuitems and toolitems over another one, and demerge them later.
</para>
<para>
-Merging is done based on the name of the XML elements. Each element is
+Merging is done based on the names of the XML elements. Each element is
identified by a path which consists of the names of its anchestors, separated
by slashes. For example, the menuitem named "Left" in the example above
has the path <literal>/ui/menubar/JustifyMenu/Left</literal> and the
{
for (child = parent->children; child != NULL; child = child->next)
{
- if (strlen (NODE_INFO (child)->name) == childname_length &&
+ if (NODE_INFO (child)->name &&
+ strlen (NODE_INFO (child)->name) == childname_length &&
!strncmp (NODE_INFO (child)->name, childname, childname_length))
{
/* if undecided about node type, set it */
!strcmp (element_name, "separator"))
{
GNode *node;
+ gint length;
if (ctx->state == STATE_TOOLBAR)
ctx->state = STATE_TOOLITEM;
else
ctx->state = STATE_MENUITEM;
+ if (!strcmp (node_name, "separator"))
+ {
+ node_name = NULL;
+ length = -1;
+ }
+ else
+ length = strlen (node_name);
node = get_child_node (self, ctx->current,
- node_name, strlen (node_name),
+ node_name, length,
NODE_TYPE_SEPARATOR,
TRUE, top);
+
if (NODE_INFO (node)->action_name == 0)
NODE_INFO (node)->action_name = action_quark;