Measure: Fix TaskMeasure

Made several fixes to TaskMeasure:
* Move to correct namespace
* Handle possible exception in update() method
* Add null pointer checks for buttonBox
* Cannot use 'Measure::MeasurePython' as template argument in addObject<>
  because the macro PROPERTY_HEADER_WITH_OVERRIDE determines the invalid
  string 'App::FeaturePythonT<FeatureT>' so that an exception is raised

Note: The changes might fix issue 20304
This commit is contained in:
wmayer
2025-03-21 15:00:12 +01:00
committed by Ladislav Michl
parent 14de080897
commit d1a84ab538
4 changed files with 32 additions and 17 deletions

View File

@@ -62,7 +62,7 @@ void StdCmdMeasure::activated(int iMsg)
{
Q_UNUSED(iMsg);
Gui::TaskMeasure* task = new Gui::TaskMeasure();
MeasureGui::TaskMeasure* task = new MeasureGui::TaskMeasure();
task->setDocumentName(this->getDocument()->getName());
Gui::Control().showDialog(task);
}