Refactoring. Remove unused argument.

This commit is contained in:
Roman Telezhynskyi 2020-11-25 09:59:36 +02:00
parent e8b69bbb88
commit 1e960e2f8a
2 changed files with 4 additions and 7 deletions

View File

@ -259,7 +259,7 @@ void VToolSeamAllowance::InsertNode(const QVector<VPieceNode> &nodes, quint32 pi
VToolSeamAllowance *saTool = qobject_cast<VToolSeamAllowance*>(VAbstractPattern::getTool(pieceId)); VToolSeamAllowance *saTool = qobject_cast<VToolSeamAllowance*>(VAbstractPattern::getTool(pieceId));
SCASSERT(saTool != nullptr); SCASSERT(saTool != nullptr);
InitNode(node, scene, doc, saTool); InitNode(node, scene, saTool);
} }
qApp->getUndoStack()->push(new SavePieceOptions(oldDet, newDet, doc, pieceId)); qApp->getUndoStack()->push(new SavePieceOptions(oldDet, newDet, doc, pieceId));
@ -1744,16 +1744,14 @@ void VToolSeamAllowance::InitNodes(const VPiece &detail, VMainGraphicsScene *sce
{ {
for (int i = 0; i< detail.GetPath().CountNodes(); ++i) for (int i = 0; i< detail.GetPath().CountNodes(); ++i)
{ {
InitNode(detail.GetPath().at(i), scene, doc, this); InitNode(detail.GetPath().at(i), scene, this);
} }
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
void VToolSeamAllowance::InitNode(const VPieceNode &node, VMainGraphicsScene *scene, VAbstractPattern *doc, void VToolSeamAllowance::InitNode(const VPieceNode &node, VMainGraphicsScene *scene, VToolSeamAllowance *parent)
VToolSeamAllowance *parent)
{ {
SCASSERT(scene != nullptr) SCASSERT(scene != nullptr)
SCASSERT(doc != nullptr)
SCASSERT(parent != nullptr) SCASSERT(parent != nullptr)
switch (node.GetTypeTool()) switch (node.GetTypeTool())

View File

@ -202,8 +202,7 @@ private:
qreal &rotationAngle, QPointF &pos); qreal &rotationAngle, QPointF &pos);
void InitNodes(const VPiece &detail, VMainGraphicsScene *scene); void InitNodes(const VPiece &detail, VMainGraphicsScene *scene);
static void InitNode(const VPieceNode &node, VMainGraphicsScene *scene, VAbstractPattern *doc, static void InitNode(const VPieceNode &node, VMainGraphicsScene *scene, VToolSeamAllowance *parent);
VToolSeamAllowance *parent);
void InitCSAPaths(const VPiece &detail) const; void InitCSAPaths(const VPiece &detail) const;
void InitInternalPaths(const VPiece &detail); void InitInternalPaths(const VPiece &detail);
void InitSpecialPoints(const QVector<quint32> &points) const; void InitSpecialPoints(const QVector<quint32> &points) const;