diff --git a/src/ViewportWidget.cpp b/src/ViewportWidget.cpp index ec0a9bd..fdade48 100644 --- a/src/ViewportWidget.cpp +++ b/src/ViewportWidget.cpp @@ -24,7 +24,7 @@ #include #include #include -#include +#include struct PntComparator { bool operator()(const gp_Pnt& a, const gp_Pnt& b) const { @@ -747,7 +747,7 @@ void ViewportWidget::drawSketch(const SketchFeature* sketch) glPointSize(5.0f); QVector lineVertices; - QMap vertexCounts; + std::map vertexCounts; for (const auto& obj : sketch->objects()) { if (obj->type() == SketchObject::ObjectType::Line) { @@ -763,9 +763,9 @@ void ViewportWidget::drawSketch(const SketchFeature* sketch) } QVector pointVertices; - for (auto it = vertexCounts.constBegin(); it != vertexCounts.constEnd(); ++it) { - if (it.value() == 1) { - const gp_Pnt& p = it.key(); + for (const auto& pair : vertexCounts) { + if (pair.second == 1) { + const gp_Pnt& p = pair.first; pointVertices << p.X() << p.Y() << p.Z(); } }