diff options
| author | Marc Jeanmougin <marc@jeanmougin.fr> | 2015-05-07 22:45:15 +0000 |
|---|---|---|
| committer | Marc Jeanmougin <marcjeanmougin@free.fr> | 2015-05-07 22:45:15 +0000 |
| commit | 57808dd1abe86ae0088a74bd88041321f5df5fb8 (patch) | |
| tree | 51510fffb8f7cc7453d49a56b9e272fdb1d567ab /src/selection-chemistry.cpp | |
| parent | better fix, using std::remove instead of std::erase (diff) | |
| download | inkscape-57808dd1abe86ae0088a74bd88041321f5df5fb8.tar.gz inkscape-57808dd1abe86ae0088a74bd88041321f5df5fb8.zip | |
fix for stl "remove"
(bzr r14123)
Diffstat (limited to 'src/selection-chemistry.cpp')
| -rw-r--r-- | src/selection-chemistry.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/selection-chemistry.cpp b/src/selection-chemistry.cpp index 1e3afc6a8..2cd4f6b4e 100644 --- a/src/selection-chemistry.cpp +++ b/src/selection-chemistry.cpp @@ -3922,7 +3922,7 @@ void sp_selection_set_mask(SPDesktop *desktop, bool apply_clip_path, bool apply_ for (GSList *i = apply_to_items ; NULL != i ; i = i->next) { reprs_to_group.push_back(static_cast<SPObject*>(i->data)->getRepr()); - remove(items_to_select.begin(),items_to_select.end(),static_cast<SPObject*>(i->data)); + items_to_select.erase(remove(items_to_select.begin(), items_to_select.end(), static_cast<SPObject*>(i->data)), items_to_select.end()); } sp_selection_group_impl(reprs_to_group, group, xml_doc, doc); @@ -3972,7 +3972,7 @@ void sp_selection_set_mask(SPDesktop *desktop, bool apply_clip_path, bool apply_ Inkscape::XML::Node *spnew = current->duplicate(xml_doc); gint position = current->position(); - remove(items_to_select.begin(),items_to_select.end(),item); + items_to_select.erase(remove(items_to_select.begin(), items_to_select.end(), item), items_to_select.end()); current->parent()->appendChild(group); sp_repr_unparent(current); group->appendChild(spnew); @@ -3996,7 +3996,7 @@ void sp_selection_set_mask(SPDesktop *desktop, bool apply_clip_path, bool apply_ for (GSList *i = items_to_delete; NULL != i; i = i->next) { SPObject *item = reinterpret_cast<SPObject*>(i->data); item->deleteObject(false); - remove(items_to_select.begin(),items_to_select.end(),item); + items_to_select.erase(remove(items_to_select.begin(), items_to_select.end(), item), items_to_select.end()); } g_slist_free(items_to_delete); @@ -4121,7 +4121,7 @@ void sp_selection_unset_mask(SPDesktop *desktop, bool apply_clip_path) { for (GSList *i = items_to_ungroup ; NULL != i ; i = i->next) { SPGroup *group = dynamic_cast<SPGroup *>(static_cast<SPObject *>(i->data)); if (group) { - remove(items_to_select.begin(),items_to_select.end(),group); + items_to_select.erase(remove(items_to_select.begin(), items_to_select.end(), group), items_to_select.end()); std::vector<SPItem*> children; sp_item_group_ungroup(group, children, false); items_to_select.insert(items_to_select.end(),children.rbegin(),children.rend()); |
