summaryrefslogtreecommitdiffstats
path: root/src/sp-item-group.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/sp-item-group.cpp')
-rw-r--r--src/sp-item-group.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/sp-item-group.cpp b/src/sp-item-group.cpp
index ab38636f6..7044f2f7f 100644
--- a/src/sp-item-group.cpp
+++ b/src/sp-item-group.cpp
@@ -405,7 +405,10 @@ sp_item_group_ungroup (SPGroup *group, GSList **children, bool do_done)
SPItem *gitem = group;
Inkscape::XML::Node *grepr = gitem->getRepr();
- g_return_if_fail (!strcmp (grepr->name(), "svg:g") || !strcmp (grepr->name(), "svg:a") || !strcmp (grepr->name(), "svg:switch"));
+ g_return_if_fail (!strcmp (grepr->name(), "svg:g")
+ || !strcmp (grepr->name(), "svg:a")
+ || !strcmp (grepr->name(), "svg:switch")
+ || !strcmp (grepr->name(), "svg:svg"));
// this converts the gradient/pattern fill/stroke on the group, if any, to userSpaceOnUse
gitem->adjust_paint_recursive (Geom::identity(), Geom::identity(), false);
@@ -546,8 +549,9 @@ sp_item_group_ungroup (SPGroup *group, GSList **children, bool do_done)
item->doWriteTransform(repr, item->transform, NULL, false);
Inkscape::GC::release(repr);
- if (children && SP_IS_ITEM (item))
- *children = g_slist_prepend (*children, item);
+ if (children && SP_IS_ITEM(item)) {
+ *children = g_slist_prepend(*children, item);
+ }
items = g_slist_remove (items, items->data);
}