Added two callbacks to App::DocumentObject
- setupObject()
- unsetupObject()
All associated code was added to App::Document
Also was added a specific flag ObjectFlag::Deleted wich is set when performing the deletion.
This one prevents thurther object structure damage if
DocumentObjectGroup::Group connains multiple links to the same feature.
Also minorr changes:
- Fix some spacing
- Ask the user if he wants to delete group content
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.