Fixing regression in method DialogTool::GetNodeName.

(grafted from 85f1cc324da4971357555e1e1f0aec51eac0f743)

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2019-05-27 19:14:07 +03:00
parent 1cf3e6dda1
commit aee0861aef
3 changed files with 7 additions and 6 deletions

View File

@ -48,6 +48,7 @@
- [#967] Variable must not include new line character.
- German translation for Inno setup script.
- [#971] Group operation do not work with VCubicBezierPath.
- Regression in method DialogTool::GetNodeName.
# Version 0.6.1 October 23, 2018
- [#885] Regression. Broken support for multi size measurements.

View File

@ -394,7 +394,7 @@ quint32 DialogTool::DNumber(const QString &baseName) const
}
//---------------------------------------------------------------------------------------------------------------------
QString DialogTool::GetNodeName(const VPieceNode &node, bool showDetails) const
QString DialogTool::GetNodeName(const VPieceNode &node, bool showPassmarkDetails) const
{
const QSharedPointer<VGObject> obj = data->GetGObject(node.GetId());
QString name = obj->name();
@ -404,14 +404,14 @@ QString DialogTool::GetNodeName(const VPieceNode &node, bool showDetails) const
int bias = 0;
qApp->TrVars()->VariablesToUser(name, 0, obj->name(), bias);
if (showDetails && node.GetReverse())
if (node.GetReverse())
{
name = QLatin1String("- ") + name;
name = QStringLiteral("- ") + name;
}
}
else
{
if (showDetails && node.IsPassmark())
if (showPassmarkDetails && node.IsPassmark())
{
switch(node.GetPassmarkLineType())
{
@ -444,7 +444,7 @@ QString DialogTool::GetNodeName(const VPieceNode &node, bool showDetails) const
}
}
if (showDetails && not node.IsCheckUniqueness())
if (not node.IsCheckUniqueness())
{
name = QLatin1Char('[') + name + QLatin1Char(']');
}

View File

@ -209,7 +209,7 @@ protected:
*/
virtual void SaveData() {}
quint32 DNumber(const QString &baseName) const;
QString GetNodeName(const VPieceNode &node, bool showDetails = false) const;
QString GetNodeName(const VPieceNode &node, bool showPassmarkDetails = false) const;
void NewNodeItem(QListWidget *listWidget, const VPieceNode &node, bool showPassmark = true);
void InitNodeAngles(QComboBox *box);