diff --git a/src/libs/vtools/visualization/line/visline.cpp b/src/libs/vtools/visualization/line/visline.cpp index 01f7a385d..02a5fb5f8 100644 --- a/src/libs/vtools/visualization/line/visline.cpp +++ b/src/libs/vtools/visualization/line/visline.cpp @@ -43,7 +43,7 @@ VisLine::VisLine(const VContainer *data, QGraphicsItem *parent) :Visualization(data), VScaledLine(parent) { - this->setZValue(1);// Show on top real tool + this->setZValue(1);// Show on top of a real tool InitPen(); } diff --git a/src/libs/vtools/visualization/line/vistoolheight.cpp b/src/libs/vtools/visualization/line/vistoolheight.cpp index 72a6cf0b8..94afe33ba 100644 --- a/src/libs/vtools/visualization/line/vistoolheight.cpp +++ b/src/libs/vtools/visualization/line/vistoolheight.cpp @@ -45,8 +45,7 @@ //--------------------------------------------------------------------------------------------------------------------- VisToolHeight::VisToolHeight(const VContainer *data, QGraphicsItem *parent) - : VisLine(data, parent), lineP1Id(NULL_ID), lineP2Id(NULL_ID), point(nullptr), base_point(nullptr), lineP1(nullptr), - lineP2(nullptr), line(nullptr), line_intersection(nullptr) + : VisLine(data, parent) { base_point = InitPoint(supportColor, this); lineP1 = InitPoint(supportColor, this); diff --git a/src/libs/vtools/visualization/line/vistoolheight.h b/src/libs/vtools/visualization/line/vistoolheight.h index 60c675fb4..9c86b9b24 100644 --- a/src/libs/vtools/visualization/line/vistoolheight.h +++ b/src/libs/vtools/visualization/line/vistoolheight.h @@ -56,14 +56,14 @@ public: private: Q_DISABLE_COPY(VisToolHeight) //base point in parent class - quint32 lineP1Id;//first point of line - quint32 lineP2Id;//second point of line - VScaledEllipse *point; - VScaledEllipse *base_point; - VScaledEllipse *lineP1; - VScaledEllipse *lineP2; - VScaledLine *line; - VScaledLine *line_intersection; + quint32 lineP1Id{NULL_ID};//first point of line + quint32 lineP2Id{NULL_ID};//second point of line + VScaledEllipse *point{nullptr}; + VScaledEllipse *base_point{nullptr}; + VScaledEllipse *lineP1{nullptr}; + VScaledEllipse *lineP2{nullptr}; + VScaledLine *line{nullptr}; + VScaledLine *line_intersection{nullptr}; void ShowIntersection(const QLineF &height_line, const QLineF &base_line); };