summaryrefslogtreecommitdiffstats
path: root/src/sp-item-group.cpp
diff options
context:
space:
mode:
authorMenTaLguY <mental@rydia.net>2008-06-11 15:56:11 +0000
committermental <mental@users.sourceforge.net>2008-06-11 15:56:11 +0000
commit7a9b77df373b64df154cda680152eb70a49d68b5 (patch)
tree273802df24aad16284dee069bcc00084513d7bad /src/sp-item-group.cpp
parentWe were using wrong gtk locale directory. Gtk's own translations were missing. (diff)
downloadinkscape-7a9b77df373b64df154cda680152eb70a49d68b5.tar.gz
inkscape-7a9b77df373b64df154cda680152eb70a49d68b5.zip
plumb XML::Documents in everywhere
(bzr r5884)
Diffstat (limited to 'src/sp-item-group.cpp')
-rw-r--r--src/sp-item-group.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/sp-item-group.cpp b/src/sp-item-group.cpp
index 109b55eb7..556a349ed 100644
--- a/src/sp-item-group.cpp
+++ b/src/sp-item-group.cpp
@@ -57,7 +57,7 @@ static void sp_group_remove_child (SPObject * object, Inkscape::XML::Node * chil
static void sp_group_order_changed (SPObject * object, Inkscape::XML::Node * child, Inkscape::XML::Node * old_ref, Inkscape::XML::Node * new_ref);
static void sp_group_update (SPObject *object, SPCtx *ctx, guint flags);
static void sp_group_modified (SPObject *object, guint flags);
-static Inkscape::XML::Node *sp_group_write (SPObject *object, Inkscape::XML::Node *repr, guint flags);
+static Inkscape::XML::Node *sp_group_write (SPObject *object, Inkscape::XML::Document *doc, Inkscape::XML::Node *repr, guint flags);
static void sp_group_set(SPObject *object, unsigned key, char const *value);
static void sp_group_bbox(SPItem const *item, NRRect *bbox, NR::Matrix const &transform, unsigned const flags);
@@ -218,7 +218,7 @@ sp_group_modified (SPObject *object, guint flags)
}
static Inkscape::XML::Node *
-sp_group_write (SPObject *object, Inkscape::XML::Node *repr, guint flags)
+sp_group_write (SPObject *object, Inkscape::XML::Document *xml_doc, Inkscape::XML::Node *repr, guint flags)
{
SPGroup *group;
SPObject *child;
@@ -229,12 +229,11 @@ sp_group_write (SPObject *object, Inkscape::XML::Node *repr, guint flags)
if (flags & SP_OBJECT_WRITE_BUILD) {
GSList *l;
if (!repr) {
- Inkscape::XML::Document *xml_doc = sp_document_repr_doc(SP_OBJECT_DOCUMENT(object));
repr = xml_doc->createElement("svg:g");
}
l = NULL;
for (child = sp_object_first_child(object); child != NULL; child = SP_OBJECT_NEXT(child) ) {
- crepr = child->updateRepr(NULL, flags);
+ crepr = child->updateRepr(xml_doc, NULL, flags);
if (crepr) l = g_slist_prepend (l, crepr);
}
while (l) {
@@ -261,7 +260,7 @@ sp_group_write (SPObject *object, Inkscape::XML::Node *repr, guint flags)
}
if (((SPObjectClass *) (parent_class))->write)
- ((SPObjectClass *) (parent_class))->write (object, repr, flags);
+ ((SPObjectClass *) (parent_class))->write (object, xml_doc, repr, flags);
return repr;
}