From 878fdb615667e524568fd990bbbdef1fd9f4f501 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Sat, 12 Nov 2016 14:05:47 +0200 Subject: [PATCH] Disable Group Nodes if the main list doesn't contain points. --HG-- branch : feature --- src/libs/vtools/dialogs/tools/dialogseamallowance.cpp | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/libs/vtools/dialogs/tools/dialogseamallowance.cpp b/src/libs/vtools/dialogs/tools/dialogseamallowance.cpp index a3456798b..807ee663f 100644 --- a/src/libs/vtools/dialogs/tools/dialogseamallowance.cpp +++ b/src/libs/vtools/dialogs/tools/dialogseamallowance.cpp @@ -69,10 +69,6 @@ DialogSeamAllowance::DialogSeamAllowance(const VContainer *data, const quint32 & InitNodesList(); connect(ui->comboBoxNodes, static_cast(&QComboBox::currentIndexChanged), this, &DialogSeamAllowance::NodeChanged); - if (ui->comboBoxNodes->count() > 0) - { - NodeChanged(0); - } connect(ui->pushButtonDefBefore, &QPushButton::clicked, this, &DialogSeamAllowance::ReturnDefBefore); connect(ui->pushButtonDefAfter, &QPushButton::clicked, this, &DialogSeamAllowance::ReturnDefAfter); @@ -599,10 +595,7 @@ void DialogSeamAllowance::InitNodesList() } else { - if (ui->comboBoxNodes->count() > 0) - { - NodeChanged(0); - } + ui->comboBoxNodes->count() > 0 ? NodeChanged(0) : NodeChanged(-1); } }