The segfault was caused by premature delete of object
TaskMultiTransformParameter::subFeature refered to.
Steps to reproduce:
1. Create a multitransform
2. Add a sub transfurmation to it
3. Press cancel
subj;
Make PasrtDesign::Transformed provide common for all features
classes interface getBaseObject() instead of specific getSupportObject ();
Refactor some TransformedParameters methods.
Also remove unused headers and fix spacing.
A final fixup for issues addressed in:
cb05b01 PartDesign/TaskDressUpParameters: fix a crash when editing a broken object
In most cases getBaseObject() is used with an exception handler which
only detects if it failed but not the reason. This modification allows
to use it without excess exception handlers.
Also add the same parameter to SketchBased::getVerifiedSketch().
- Moved all common code for part design features view providers to a base
class.
- Move shared code for Sketch based features to newly created
ViewProviderSketchBased class
- Add ViewProviderSketchBased to initialization
- Make Pad and Pocket ViewProviders to use the shared code
- Minor fixes to TaskFeatureParameters and some derived classes
The function getBaseShape() is removed and replaced with getBaseObject()
because it doesn't make a lot of scense: getBaseShape() masked the
base's class implementation (rather than redefine a virtual) which was
better in words of code reuse.
Also BaseFeature and Base properties relations are defined now in a
little another way.
Give a massive refactoring to Task dialogs for pocket and pad.
This commit features:
* Make Task dialogs for pocket and pad look nice in side-by side diff and
cross import features missing in each other.
* As a result it fixes several minor bugs.
* Gives a rework to the UpdateUI function.
* This one also fixes offset option support and migrates it to use unit
framework.
Added a new class: TaskDlgFeatureBased which currently contains common
code for TaskDlgSketcherBasedParameters::reject() as well as the same
methode for TaskDlgDressUpParameters.
It's likely that other Feature task dialogs will inherit this class too.
* remove an error message if adding a sketchbased feature without a body
* add champfer or fillet old workflow support
Also rework finishFeature() so at least champfer and fillet may be
inserted into any place of any apropriate body(not only the active one) of the body.
PartDesign: make datum features work outside of body/part
PartDesign old workflow: remove a few messageboxes about no part
PartDesign: old workflow: multitransform without body
Still has visibility issues, but generally works.
PartDesign Revolution used to fail, when an edge of a sketch was
selected as an axis of revolution. This is fixed by this commit.
Also, made it support selecting an edge from the sketch the revolution
itself is made from.
Rework combobox filling and link hadling for revolution and transformed features, in order to get rid of hard-coded item indexes and make the lists more dynamic.