Community
Participate
Working Groups
Given a model A which contains cross-references to a model B. Both models can be visualized by a nested editor withing a multi-editor. When model A is loaded and a cross reference, also known as inter-model connection, is to be created, this may lead to automatically loading of model B. This could lead to recursive calls of refreshChildren (in MultiEditorContainerEditPart), as the cross reference is only resolved during a refreshChildren call. If that happens, the resursively called refreshChildren causes new edit parts to be created for model elements which were already created in the first refreshChildren.
MultiEditorModelContainerEditPart simply called refreshChildren when new model elements (i.e. nested editor's diagrams) were added. This caused the recursive call of refreshChildren as described by that bug report. This is fixed now by avoiding calling refreshChildren on model changes (in propertyChanged), instead edit parts are added, removed or changed as needed without (re-) evaluating all child edit parts.
Created attachment 172586 [details] mylyn/context/zip