summaryrefslogtreecommitdiff
path: root/gtk/gtkuimanager.c
diff options
context:
space:
mode:
authorMatthias Clasen <maclas@gmx.de>2004-09-04 02:55:13 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2004-09-04 02:55:13 +0000
commit3636328e69078d233c14f62a348e41a1e03711f4 (patch)
tree6b37d9b3daa109140c36010a07197d673702a455 /gtk/gtkuimanager.c
parent5445cbc7b0fd54d57229f9127084be0afc5f416f (diff)
downloadgtk+-3636328e69078d233c14f62a348e41a1e03711f4.tar.gz
Don't print out attributes for the <ui> root node. (#151752, Lorenzo Gil
Fri Sep 3 22:45:03 2004 Matthias Clasen <maclas@gmx.de> * gtk/gtkuimanager.c (print_node): Don't print out attributes for the <ui> root node. (#151752, Lorenzo Gil Sánchez)
Diffstat (limited to 'gtk/gtkuimanager.c')
-rw-r--r--gtk/gtkuimanager.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/gtk/gtkuimanager.c b/gtk/gtkuimanager.c
index 7133be1f0e..459f97102c 100644
--- a/gtk/gtkuimanager.c
+++ b/gtk/gtkuimanager.c
@@ -2673,12 +2673,15 @@ print_node (GtkUIManager *self,
g_string_append_printf (buffer, open_tag_format[mnode->type],
indent_level, "");
- if (mnode->name)
- g_string_append_printf (buffer, " name=\"%s\"", mnode->name);
-
- if (mnode->action_name)
- g_string_append_printf (buffer, " action=\"%s\"",
- g_quark_to_string (mnode->action_name));
+ if (mnode->type != NODE_TYPE_ROOT)
+ {
+ if (mnode->name)
+ g_string_append_printf (buffer, " name=\"%s\"", mnode->name);
+
+ if (mnode->action_name)
+ g_string_append_printf (buffer, " action=\"%s\"",
+ g_quark_to_string (mnode->action_name));
+ }
g_string_append (buffer,
close_tag_format[mnode->type] ? ">\n" : "/>\n");