Minor fixes for dialog Piece path.
--HG-- branch : release
This commit is contained in:
parent
7840bf04eb
commit
dce880e270
|
@ -348,7 +348,7 @@ void DialogPiecePath::NodeChanged(int index)
|
|||
QString w2Formula = node.GetFormulaSAAfter();
|
||||
if (w2Formula != currentSeamAllowance)
|
||||
{
|
||||
ui->pushButtonDefBefore->setEnabled(true);
|
||||
ui->pushButtonDefAfter->setEnabled(true);
|
||||
}
|
||||
if (w2Formula.length() > 80)// increase height if needed.
|
||||
{
|
||||
|
@ -458,12 +458,20 @@ void DialogPiecePath::PassmarkChanged(int index)
|
|||
void DialogPiecePath::ReturnDefBefore()
|
||||
{
|
||||
ui->plainTextEditFormulaWidthBefore->setPlainText(currentSeamAllowance);
|
||||
if (QPushButton* button = qobject_cast<QPushButton*>(sender()))
|
||||
{
|
||||
button->setEnabled(false);
|
||||
}
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------------------------------------------------
|
||||
void DialogPiecePath::ReturnDefAfter()
|
||||
{
|
||||
ui->plainTextEditFormulaWidthAfter->setPlainText(currentSeamAllowance);
|
||||
if (QPushButton* button = qobject_cast<QPushButton*>(sender()))
|
||||
{
|
||||
button->setEnabled(false);
|
||||
}
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------------------------------------------------
|
||||
|
@ -571,6 +579,11 @@ void DialogPiecePath::EvalWidthBefore()
|
|||
bool flagFormula = false; // fake flag
|
||||
Eval(formula, flagFormula, ui->labelResultBefore, postfix, false, true);
|
||||
|
||||
if (formula != currentSeamAllowance)
|
||||
{
|
||||
ui->pushButtonDefBefore->setEnabled(true);
|
||||
}
|
||||
|
||||
UpdateNodeSABefore(GetFormulaSAWidthBefore());
|
||||
}
|
||||
|
||||
|
@ -583,6 +596,11 @@ void DialogPiecePath::EvalWidthAfter()
|
|||
bool flagFormula = false; // fake flag
|
||||
Eval(formula, flagFormula, ui->labelResultAfter, postfix, false, true);
|
||||
|
||||
if (formula != currentSeamAllowance)
|
||||
{
|
||||
ui->pushButtonDefAfter->setEnabled(true);
|
||||
}
|
||||
|
||||
UpdateNodeSABefore(GetFormulaSAWidthAfter());
|
||||
}
|
||||
|
||||
|
|
|
@ -326,7 +326,7 @@
|
|||
<item>
|
||||
<widget class="QComboBox" name="comboBoxNodes">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
|
|
Loading…
Reference in New Issue
Block a user