[FEM] Refactor TaskFemConstraintOnBoundary (#6615)

* Now the behavior is consistent with behavior of PD fillets, for example.
See https://forum.freecadweb.org/viewtopic.php?f=18&t=67135#p580192. In the
future it may be possible to reuse some code from there.

* When the last selected item is removed we need to reset the existing
highlighting separately.

* Use `Gui::ButtonGroup` in `TaskFemConstraintOnBoundary`
This commit is contained in:
Ajinkya Dahale
2022-03-20 20:02:10 -04:00
committed by GitHub
parent d6a9a941ac
commit 300fbc22ea
11 changed files with 76 additions and 87 deletions

View File

@@ -92,10 +92,8 @@ TaskFemConstraintSpring::TaskFemConstraintSpring(ViewProviderFemConstraintSpring
}
//Selection buttons
connect(ui->btnAdd, SIGNAL(toggled(bool)),
this, SLOT(_addToSelection(bool)));
connect(ui->btnRemove, SIGNAL(toggled(bool)),
this, SLOT(_removeFromSelection(bool)));
buttonGroup->addButton(ui->btnAdd, (int)SelectionChangeModes::refAdd);
buttonGroup->addButton(ui->btnRemove, (int)SelectionChangeModes::refRemove);
updateUI();
}