PD: Add template helper functions to safely access feature or view provider

In subclasses of TaskFeatureParameters use the new helper functions and check for null pointer. This fixes #15453
This commit is contained in:
wmayer
2024-07-18 13:40:08 +02:00
parent b1029bc682
commit 010a36df30
13 changed files with 836 additions and 747 deletions

View File

@@ -86,7 +86,7 @@ void TaskPadParameters::updateUI(int index)
void TaskPadParameters::onModeChanged(int index)
{
PartDesign::Pad* pcPad = static_cast<PartDesign::Pad*>(vp->getObject());
auto pcPad = getObject<PartDesign::Pad>();
switch (static_cast<Mode>(index)) {
case Mode::Dimension: