Bug 497449

Summary: Improve technically the collapse of regions
Product: [Modeling] Sirius Reporter: Laurent Redor <laurent.redor>
Component: DiagramAssignee: Project Inbox <sirius.diagram-inbox>
Status: NEW --- QA Contact:
Severity: enhancement    
Priority: P3 CC: pierre-charles.david
Version: unspecifiedKeywords: triaged
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Laurent Redor CLA 2016-07-07 02:57:01 EDT
As explained in commits [1] and [2], the height and width have been set to -1 in AirXYLayoutEditPolicy.getConstraintFor(Request, GraphicalEditPart, Rectangle) for facility reason:
* commit [1] to react to show/hide label
* commit [2] to react to collapse of horizontal stack regions.

I think it would be better to directly handle these constraint in the "resize" commands:
* RegionCollapseAwarePropertyHandlerEditPolicy.getLayoutConstraintsCommand(boolean, Command) for collapse case
* Another policy/request for show/hide label case

[1] http://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=77d6b28496cd23c13e37484c66b12358b9f33bf4
[2] http://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=656a1a52e2e29e08e77d783fa2e690a140311ffb