From 3c6122df79f4d6e86d7afa0e6c4b64403de7bc44 Mon Sep 17 00:00:00 2001 From: monsta Date: Sun, 21 Aug 2016 03:29:50 +0300 Subject: drop a large amount of completely unused code --- eel/eel-xml-extensions.c | 73 ------------------------------------------------ 1 file changed, 73 deletions(-) (limited to 'eel/eel-xml-extensions.c') diff --git a/eel/eel-xml-extensions.c b/eel/eel-xml-extensions.c index 2bcd4477..de09b99f 100644 --- a/eel/eel-xml-extensions.c +++ b/eel/eel-xml-extensions.c @@ -42,12 +42,6 @@ eel_xml_get_children (xmlNodePtr parent) return parent->children; } -xmlNodePtr -eel_xml_get_root_children (xmlDocPtr document) -{ - return eel_xml_get_children (xmlDocGetRootElement (document)); -} - xmlNodePtr eel_xml_get_child_by_name_and_property (xmlNodePtr parent, const char *child_name, @@ -78,29 +72,6 @@ eel_xml_get_child_by_name_and_property (xmlNodePtr parent, return NULL; } -/* return a child of the passed-in node with a matching name */ - -xmlNodePtr -eel_xml_get_child_by_name (xmlNodePtr parent, - const char *child_name) -{ - xmlNodePtr child; - - if (parent == NULL) - { - return NULL; - } - for (child = eel_xml_get_children (parent); child != NULL; child = child->next) - { - if (strcmp (child->name, child_name) == 0) - { - return child; - } - } - return NULL; -} - - xmlNodePtr eel_xml_get_root_child_by_name_and_property (xmlDocPtr document, const char *child_name, @@ -114,50 +85,6 @@ eel_xml_get_root_child_by_name_and_property (xmlDocPtr document, property_value); } -/** - * eel_xml_get_property_for_children - * - * Returns a list of the values for the specified property for all - * children of the node that have the specified name. - * - * @parent: xmlNodePtr representing the node in question. - * @child_name: child element name to look for - * @property: name of propety to reutnr for matching children that have the property - * - * Returns: A list of keywords. - * - **/ -GList * -eel_xml_get_property_for_children (xmlNodePtr parent, - const char *child_name, - const char *property_name) -{ - GList *properties; - xmlNode *child; - xmlChar *property; - - properties = NULL; - - for (child = eel_xml_get_children (parent); - child != NULL; - child = child->next) - { - if (strcmp (child->name, child_name) == 0) - { - property = xmlGetProp (child, property_name); - if (property != NULL) - { - properties = g_list_prepend (properties, - g_strdup (property)); - xmlFree (property); - } - } - } - - /* Reverse so you get them in the same order as the XML file. */ - return g_list_reverse (properties); -} - xmlChar * eel_xml_get_property_translated (xmlNodePtr parent, const char *property_name) -- cgit v1.2.1