* Fixed a mistake made in getSubObjectListFlatten()
* Applied modifications according to review comments
Signed-off-by: CalligaroV <vincenzo.calligaro@gmail.com>
* Formatted and refactored code imported for the DocumentObject class
* Formatted and refactored code imported for the SubObjectT class
Signed-off-by: CalligaroV <vincenzo.calligaro@gmail.com>
* Added test for SubObjectT::hasSubObject()
* Added test for SubObjectT::hasSubElement()
* Added test for SubObjectT::normalize()
* Added test for SubObjectT::normalized()
Signed-off-by: CalligaroV <vincenzo.calligaro@gmail.com>
* Added SubObjectT methods normalize(), normalized(), hasSubObject() and hasSubElement()
* Updated DocumentObject::getSubObjectList()
* Applied modifications to make the code compile
It is originally used for dependency selection when copying object.
Modified to improve auto dependency selection, and for use by Link
configuration object setup, which also involves dependency selection.
The problem happens when partial loading is enabled. If document A
contains a link to some object in document B, it will load B as partial
document with only that object and its necessary dependencies. But if
document A contains another link to some object in document C which also
has a link to some object in document B, the link in document C may not
be restored, because document B is partially loaded without the linked
object. This patch will check for this case and reload document B for
more objects.
See an example reported in
https://forum.freecadweb.org/viewtopic.php?p=495078#p495078
Derived from App::DocumentObjectT to add support of sub object
Also some minor changes to App::DocumentObjectT
Changed Gui::SelectionChanges to make use of SubObjectT
* Add new API and signal handler in document observer
* Pre initialize python handler function to improve performance. In
case Python code use dynamic patching, i.e. add class method at
runtime (which is rare and should be discouraged), the python feature
can be re-initialized by simply assign proeprty Proxy again.
* Add property tracking in DocumentObjectT
* WidgetFactory adds support for accepting python QIcon, which is used
by ViewProviderPythonFeature