summaryrefslogtreecommitdiffstats
path: root/src/prefs-utils.cpp
diff options
context:
space:
mode:
authorPeter Moulder <peter.moulder@monash.edu>2008-06-05 06:35:29 +0000
committerpjrm <pjrm@users.sourceforge.net>2008-06-05 06:35:29 +0000
commit14889917b80b44699d014e24259cc14d8b11d90f (patch)
treef85335c7448794b18d1b1dcf5784db4b31f64bbd /src/prefs-utils.cpp
parentaddress some cast-away-const warnings. (diff)
downloadinkscape-14889917b80b44699d014e24259cc14d8b11d90f.tar.gz
inkscape-14889917b80b44699d014e24259cc14d8b11d90f.zip
Remove unused and buggy-looking function get_pref_children.
(bzr r5815)
Diffstat (limited to 'src/prefs-utils.cpp')
-rw-r--r--src/prefs-utils.cpp14
1 files changed, 1 insertions, 13 deletions
diff --git a/src/prefs-utils.cpp b/src/prefs-utils.cpp
index a8f358faf..7a950c3c3 100644
--- a/src/prefs-utils.cpp
+++ b/src/prefs-utils.cpp
@@ -50,19 +50,7 @@ gchar * create_pref(gchar const *father_path, gchar const *child){
father->appendChild(repr);
return g_strdup_printf("%s.%s", father_path,child);
}
-/**
-\brief gets the list of children from a pref. Please free all that stuff after use.
-*/
-bool get_pref_children(gchar const *father_path, GSList ** children){
- Inkscape::XML::Node *father = inkscape_get_repr(INKSCAPE, father_path);
- if (! father ) return false;
- Inkscape::XML::Node *child_repr = sp_repr_children(father);
- while (child_repr) {
- *children = g_slist_prepend(*children, g_strdup_printf("%s.%s",father_path,child_repr->attribute("id")));
- child_repr = sp_repr_next(child_repr);
- }
-}
/**
\brief gets the nth children of a pref, starting from one (first child <=> n=1). returns NULL if out of bounds or father does not exist. Please free all that stuff after use.
*/
@@ -162,7 +150,7 @@ prefs_get_string_attribute(gchar const *path, gchar const *attr)
{
Inkscape::XML::Node *repr = inkscape_get_repr(INKSCAPE, path);
if (repr) {
- return (char *) repr->attribute(attr);
+ return repr->attribute(attr);
}
return NULL;
}