Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 317795

Summary: Problem when cross-referenced diagrams are automatically resolved
Product: z_Archived Reporter: Jens Von Pilgrim <developer>
Component: Gef3dAssignee: Jens Von Pilgrim <developer>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
mylyn/context/zip none

Description Jens Von Pilgrim CLA 2010-06-24 05:39:41 EDT
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.
Comment 1 Jens Von Pilgrim CLA 2010-06-24 05:43:36 EDT
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.
Comment 2 Jens Von Pilgrim CLA 2010-06-24 05:43:39 EDT
Created attachment 172586 [details]
mylyn/context/zip