Fix crash after creating an elliptical arc.

This commit is contained in:
Roman Telezhynskyi 2020-11-27 10:34:23 +02:00
parent 3ce704d039
commit 53f686e919
2 changed files with 5 additions and 0 deletions

View File

@ -3,6 +3,7 @@
- Improve canceling nesting. - Improve canceling nesting.
- Fix incorrect nesting status for valid cases. - Fix incorrect nesting status for valid cases.
- Improve crossing check for the layout algorithm. - Improve crossing check for the layout algorithm.
- Fix crash after creating an elliptical arc.
# Version 0.7.40 Nov 23, 2020 # Version 0.7.40 Nov 23, 2020
- New function Warning. - New function Warning.

View File

@ -2473,6 +2473,9 @@ void VToolOptionsPropertyBrowser::ChangeDataToolEllipticalArc(VPE::VProperty *pr
switch (PropertiesList().indexOf(id)) switch (PropertiesList().indexOf(id))
{ {
case 0: // AttrName
Q_UNREACHABLE();//The attribute is read only
break;
case 40://AttrRadius1 case 40://AttrRadius1
SetFormulaRadius1(property); SetFormulaRadius1(property);
break; break;
@ -3067,6 +3070,7 @@ void VToolOptionsPropertyBrowser::ShowOptionsToolEllipticalArc(QGraphicsItem *it
i->ShowVisualization(true); i->ShowVisualization(true);
formView->setTitle(tr("Elliptical arc")); formView->setTitle(tr("Elliptical arc"));
AddPropertyObjectName(i, tr("Name:"), true);
AddPropertyParentPointName(i->CenterPointName(), tr("Center point:"), AttrCenter); AddPropertyParentPointName(i->CenterPointName(), tr("Center point:"), AttrCenter);
AddPropertyFormula(tr("Radius:"), i->GetFormulaRadius1(), AttrRadius1); AddPropertyFormula(tr("Radius:"), i->GetFormulaRadius1(), AttrRadius1);
AddPropertyFormula(tr("Radius:"), i->GetFormulaRadius2(), AttrRadius2); AddPropertyFormula(tr("Radius:"), i->GetFormulaRadius2(), AttrRadius2);