Community
Participate
Working Groups
Actually, as described at the news:e78lvr$l49$1@utils.eclipse.org, the GenCompartment#hideIfEmpty property does not affect compartment behaviour. Expected: compartments with such property set to true, should not appear at the diagram until they have at least one sub element to show.
Not for 1.0
Moving to 2.1
Created attachment 101592 [details] ListCompartmentEditPolicy and its use Here's an example how one may approach the issue (using Ecore Diagram Example - updating Class and its compartments). Dmitri, could you please review and let me know if it's reasonable from GEF standpoint. Updating compartment figure visibility from #refreshChildren is my major concern. BTW, What I like about introduced EditPolicy is that it's sort of right fit for compartments, much better than ResizableCompartmentEditPolicy. Since we generate figures that do not allow to resize compartment anyway, and compartments themselves don't need to be drag-dropped, why should be keep all the stuff then?
Method refreshChildren() is supposed to change editpart visually so there should be no problems. I've tested the patch and it seems to be working fine; reassigning to Artem.
Need to move ListCompartmentEditPolicy to Runtime to avoid generating it for each non-resizable compartment. It's too late for such changes in this dev. cycle, will get addressed in the next.
[GMF Restructure] Bug 319140 : product GMF and component Generation was the original product and component for this bug