aboutsummaryrefslogtreecommitdiff
path: root/libdbusmenu-glib
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2010-01-21 17:16:50 -0600
committerTed Gould <ted@gould.cx>2010-01-21 17:16:50 -0600
commit72ccbb44a4d05515e7e29f23ff3e438352d84821 (patch)
tree1e00149c6e469b61485168e9f7fa190a5295f807 /libdbusmenu-glib
parent4dea36b65076939e4f556a0f5e9d5c81c1553eb2 (diff)
downloadlibdbusmenu-72ccbb44a4d05515e7e29f23ff3e438352d84821.tar.gz
libdbusmenu-72ccbb44a4d05515e7e29f23ff3e438352d84821.tar.bz2
libdbusmenu-72ccbb44a4d05515e7e29f23ff3e438352d84821.zip
Removing looking for the revision on the XML
Diffstat (limited to 'libdbusmenu-glib')
-rw-r--r--libdbusmenu-glib/client.c31
1 files changed, 1 insertions, 30 deletions
diff --git a/libdbusmenu-glib/client.c b/libdbusmenu-glib/client.c
index 01dfed7..c4e9860 100644
--- a/libdbusmenu-glib/client.c
+++ b/libdbusmenu-glib/client.c
@@ -514,34 +514,6 @@ build_proxies (DbusmenuClient * client)
return;
}
-/* Get the "revision" attribute of the node, parse it and
- return it. Also we're checking to ensure the node
- is a 'menu' here. */
-static gint
-parse_node_get_revision (xmlNodePtr node)
-{
- if (g_strcmp0((gchar *)node->name, "menu") != 0) {
- /* This kills some nodes early */
- g_warning("XML Node is not 'menu' it is '%s'", node->name);
- return 0;
- }
-
- xmlAttrPtr attrib;
- for (attrib = node->properties; attrib != NULL; attrib = attrib->next) {
- if (g_strcmp0((gchar *)attrib->name, "revision") == 0) {
- if (attrib->children != NULL) {
- guint revision = (guint)g_ascii_strtoull((gchar *)attrib->children->content, NULL, 10);
- /* g_debug ("Found ID: %d", id); */
- return revision;
- }
- break;
- }
- }
-
- g_warning("Unable to find a revision on the node");
- return 0;
-}
-
/* Get the ID attribute of the node, parse it and
return it. Also we're checking to ensure the node
is a 'menu' here. */
@@ -764,7 +736,6 @@ parse_layout (DbusmenuClient * client, const gchar * layout)
xmldoc = xmlReadMemory(layout, g_utf8_strlen(layout, 16*1024), "dbusmenu.xml", NULL, 0);
xmlNodePtr root = xmlDocGetRootElement(xmldoc);
- gint revision = parse_node_get_revision(root);
DbusmenuMenuitem * oldroot = priv->root;
priv->root = parse_layout_xml(client, root, priv->root, NULL, priv->menuproxy);
@@ -781,7 +752,7 @@ parse_layout (DbusmenuClient * client, const gchar * layout)
g_signal_emit(G_OBJECT(client), signals[ROOT_CHANGED], 0, priv->root, TRUE);
}
- return revision;
+ return 1;
}
/* When the layout property returns, here's where we take care of that. */