From a7f2b2ba3f13ceb60376802f4a31e104153839e8 Mon Sep 17 00:00:00 2001 From: Marc Jeanmougin Date: Tue, 17 Feb 2015 03:00:37 +0100 Subject: At first, I was thinking "I just have to go to the selection file, and change that GSList* with a std::list, then resolve the few problems" So, i tried that. And I will continue tomorrow, and the days after, on and on. (bzr r13922.1.1) --- src/gradient-drag.cpp | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'src/gradient-drag.cpp') diff --git a/src/gradient-drag.cpp b/src/gradient-drag.cpp index 154b7339b..649928060 100644 --- a/src/gradient-drag.cpp +++ b/src/gradient-drag.cpp @@ -2082,9 +2082,9 @@ void GrDrag::updateDraggers() this->draggers = NULL; g_return_if_fail(this->selection != NULL); - - for (GSList const* i = this->selection->itemList(); i != NULL; i = i->next) { - SPItem *item = SP_ITEM(i->data); + SelContainer list = this->selection->itemList(); + for (SelContainer::const_iterator i=list.begin();i!=list.end();i++) { + SPItem *item = SP_ITEM(*i); SPStyle *style = item->style; if (style && (style->fill.isPaintserver())) { @@ -2151,9 +2151,9 @@ void GrDrag::updateLines() g_return_if_fail(this->selection != NULL); - for (GSList const* i = this->selection->itemList(); i != NULL; i = i->next) { - - SPItem *item = SP_ITEM(i->data); + SelContainer list = this->selection->itemList(); + for (SelContainer::const_iterator i=list.begin();i!=list.end();i++) { + SPItem *item = SP_ITEM(*i); SPStyle *style = item->style; @@ -2295,8 +2295,9 @@ void GrDrag::updateLevels() g_return_if_fail (this->selection != NULL); - for (GSList const* i = this->selection->itemList(); i != NULL; i = i->next) { - SPItem *item = SP_ITEM(i->data); + SelContainer list = this->selection->itemList(); + for (SelContainer::const_iterator i=list.begin();i!=list.end();i++) { + SPItem *item = SP_ITEM(*i); Geom::OptRect rect = item->desktopVisualBounds(); if (rect) { // Remember the edges of the bbox and the center axis -- cgit v1.2.3