diff options
| author | Marc Jeanmougin <marc@jeanmougin.fr> | 2015-12-09 15:49:59 +0000 |
|---|---|---|
| committer | Marc Jeanmougin <marcjeanmougin@free.fr> | 2015-12-09 15:49:59 +0000 |
| commit | 50ab3a3c4215474d437f9adcc4b725bed26767d7 (patch) | |
| tree | 0241555b1dc6efe9f35db7696c7e440e8a56bada /src/guide-snapper.cpp | |
| parent | Remove unused var in header file (diff) | |
| parent | update to trunk (diff) | |
| download | inkscape-50ab3a3c4215474d437f9adcc4b725bed26767d7.tar.gz inkscape-50ab3a3c4215474d437f9adcc4b725bed26767d7.zip | |
Merge glib_hunt: cppification and removal of many glib GList/GSList/GHashTable
(bzr r14520)
Diffstat (limited to 'src/guide-snapper.cpp')
| -rw-r--r-- | src/guide-snapper.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/guide-snapper.cpp b/src/guide-snapper.cpp index 960caed67..17f2d9583 100644 --- a/src/guide-snapper.cpp +++ b/src/guide-snapper.cpp @@ -44,11 +44,10 @@ Inkscape::GuideSnapper::LineList Inkscape::GuideSnapper::_getSnapLines(Geom::Poi } SPGuide const *guide_to_ignore = _snapmanager->getGuideToIgnore(); - - for (GSList const *l = _snapmanager->getNamedView()->guides; l != NULL; l = l->next) { - SPGuide const *g = SP_GUIDE(l->data); - if (g != guide_to_ignore) { - s.push_back(std::pair<Geom::Point, Geom::Point>(g->getNormal(), g->getPoint())); + std::vector<SPGuide *> guides = _snapmanager->getNamedView()->guides; + for(std::vector<SPGuide *>::const_iterator it = guides.begin() ; it != guides.end(); ++it) { + if ((*it) != guide_to_ignore) { + s.push_back(std::pair<Geom::Point, Geom::Point>((*it)->getNormal(), (*it)->getPoint())); } } |
