[419926] Fix a rebranding issue on SiriusTestCase

SiriusTestCase.deactivateSirius()->deactivateViewpoint()
SiriusTestCase.initSirius()->initViewpoint()
SiriusTestCase.findSirius()->findViewpoint()

Bug: 419926
Change-Id: Id87adf17b5f67adc98e095e8d86d8473b956cb77
Signed-off-by: Esteban Dugueperoux <esteban.dugueperoux@obeo.fr>
[437097] Update policies concerned by this feature

* Use of PrecisionPoint: PrecisionPoint is now used for move delta to
avoir problem of rounded value caused by zoom level.
* AirResizableEditPolicy:
** This policy already adapts the getMoveCommand for edges with a tree
router. It now also adapts the getMoveCommand for edges with rectlinear
and oblique router to move only the segment "attached" to the move node.
** The getAlignCommand has also been adapted to having the same behavior
as getMoveCommand but on align action.
** The new command SetConnectionBendpointsAccordingToExtremityMove has
been created to handle the edge move.
* SpecificBorderItemSelectionEditPolicy: Same changes as
AirResizableEditPolicy for getMoveCommand
* ArrangeAllWithAutoSize, PinnedElementsLayoutProvider &
AbstractCompositeLayoutProvider: Fix a bug when an arrange selection is
launched. This avoids to have bad size information during the
getMoveCommand and especially in the code added.

Bug: 437097
Change-Id: I2b4b47f2a704b54595d04ea3ce993710389a56d9
Signed-off-by: Laurent Redor <laurent.redor@obeo.fr>
[441090] Specification - another update for shortcut

The shortcut CTRL+r can not be used.

Change-Id: Icb49b6c8facb96f13a177d56cca334416f3e838a
Signed-off-by: Laurent Redor <laurent.redor@obeo.fr>
[442231] Have InvalidPermissionCommand/LockedInstanceException manages
several EObjects

Update InvalidPermissionCommand/LockedInstanceException without breaking
API to allow take several EObjects.

Bug: 442231
Change-Id: Ie0b495e90334eb383c0eb4827a67a76241a88fb1
Signed-off-by: Esteban Dugueperoux <esteban.dugueperoux@obeo.fr>
[441711] Replace "New Detail: new representation" menu by simplier entry

Bug: 441711
Change-Id: I2118c8e1700ce3cd9dedeb8920ce0ff82f6b4639
Signed-off-by: Belqassim Djafer <belqassim.djafer@obeo.fr>
[441586] Set default value for Intersection label expression in Cross
Table

Bug: 441586
Change-Id: I8856487f3a5a8d9ed8b2487ad5211bc4e3e86304
Signed-off-by: Jessy MALLET <jessy.mallet@obeo.fr>
[441709] Generate Sirius meta-model with EMF 2.10

Change-Id: Ie3df7a8ee61a916adc9b3c0911a3b0942e24ec6c
[441090] Resize a container without modifying the contained elements
location

* SiriusResizeTracker: Override of {@link ResizeTracker} to allow a
resize that also moves all children.
* AirResizableEditPolicy:
** Use our own ResizeTracker to set the "flag"
SiriusResizeTracker.FIX_CHILDREN_KEY when the corresponding shortcut is
pressed.
** Adapt buildResizeCommand to also resize children (according to
SiriusResizeTracker.FIX_CHILDREN_KEY)
* MoveViewOperation (and InstanceRoleResizableEditPolicy) : Move the
existing MoveViewOperation from sequence to diagram.

Bug: 441090
Change-Id: I5f603e7c1aa5abe74e49b6c5c2325e2efe86801d
Signed-off-by: Laurent Redor <laurent.redor@obeo.fr>
[441262] replace navigate menu by two menus "new" and "open"

instead of a "Navigate" top-level menu entry with mixed entries for
creating new representations and opening existing ones, I have created
two top-level menus:
* One named "New", which lists only the available actions to create new
representations on the selected element.
* One named "Open", which lists only the existing representations on the
selected element.
If any of these does not contain anything, it should not be visible at
all.

Bug: 441262
Change-Id: I597ca58ff915c38d61b97c8540df9ea9bfa58532
Signed-off-by: Belqassim Djafer <belqassim.djafer@obeo.fr>
[442076] Replace "viewpoint" by "sirius" in several places in "Sirius
Specifier Manual -> Using the Extended Editing Framework with Sirius".

Bug: 442076
Change-Id: Ieb343c9b4da0a75594f315005d10582658e1cbd2
Signed-off-by: Belqassim Djafer <belqassim.djafer@obeo.fr>
[441483] Source code for automated tests (JUnit & SWTbot)

This is the code accepted as CQ #8550, with a single small change in
plugins/org.eclipse.sirius.sample.interactions.design/doc/license.txt,
as per requested by the IP team (see comment #5 in the CQ).

For reference, this corresponds to the state of the code in the old
Viewpoint repo as of commit f33e43835783f3515b4fb9df1819b9f8ea7b3347
there.

Bug: 441483
Change-Id: I66351a2a699b4db9cdcf3aa32c1026af2f191988
Signed-off-by: Pierre-Charles David <pierre-charles.david@obeo.fr>
[441483] Update test code

Update the test code to incorporate the changes which were made
internally after the snapshot that was sent for review in CQ #8550.

This brings the test code to the state of commit
94fa73888bef2c177d7d1f3e81da3ebfe3adf78c in the internal repo.

Bug: 441483
Change-Id: Ia83154cb1be1e8a66d391fec48791d91bc6381b4
Signed-off-by: Pierre-Charles David <pierre-charles.david@obeo.fr>
[441262] Fix to avoid NPE if navigate menu has been removed or changed

Fix regression caused by replacing navigate menu by two menu "new" and
"open".

Bug: 441262
Change-Id: Id0e8ecbb53ee108449e7a38de95b6de2e553a2a6
Signed-off-by: Belqassim Djafer <belqassim.djafer@obeo.fr>
[427872] AbstractDeleteDRepresentationElementTask and subclasses cleanup

The AbstractDeleteDRepresentationElementTask has been renamed into
DeleteDRepresentationElementTask, the dialect specific subclasses have
been removed.

Bug: 427872
Change-Id: Ib2cf475bc08def8da95b6675f1b82fdd2d03ce04
Signed-off-by: Maxime PORHEL <maxime.porhel@obeo.fr>
[427869] Remove oes.tools.internal.util.CrossReferenceAdapter

This cleanup step removes the CrossReferenceAdapter and the related code.
This adapter is never installed. And the only call try to get an
existing instance and do the same job than the
DanglingRefRemovalTrigger.

Bug: 427869
Change-Id: I3eac7bc531c1e62be512f8b7ec8fc446ad15bd06
Signed-off-by: Maxime PORHEL <maxime.porhel@obeo.fr>
[427869] Add a label to the DeleteDRepresentationTask

Bug: 427869
Change-Id: I514e2d5a9e2f53a6856cec33ebcc7519609b6b02
Signed-off-by: Maxime PORHEL <maxime.porhel@obeo.fr>
[427869] Do not remove a representation from its resource root contents

A Representation is never stored as root of a resource.

Bug: 427869
Change-Id: I18b1e918d52dce4f9b546a2706c9988c94b46fd9
Signed-off-by: Maxime PORHEL <maxime.porhel@obeo.fr>
[427869] Simplify DeleteDRepresentationTask

Get the model accessor from the registry only once.
DeleteRepresentationTask is added when deleteReferences == false, the task is created in
DeleteSeveralDDiagramElementsTask. This task will be executed before the
DeleteDRepresentationElementTask created on the same element. So we can
remove the GMFUtil.tearDownOutgoingReferences as its goal has no sense:
when an element is detached/removed from its container, the cross
referencer adapter is notified , the unsetTarget is called and the
inverse references from this object are removed. Furthermore the
DeleteDrepresentationElementTask (or later the
DanglingRefRemovalTrigger) will perform a eDelete on the current
DRepresentation, and the
ECrossReferenceAdatper should then be up to date.

Bug: 427869
Change-Id: I8c4ceaf8a387d83cb10e1611325cabc4c25bf5ca
Signed-off-by: Maxime PORHEL <maxime.porhel@obeo.fr>
[427869] Avoid unnecessary eAllContents on DDiagram

because a DDiagram is never stored in another DDiagram.
The metamodel was able to do it before bug 427247 which has removed the
DNode.ownedDetails and DDiagramElementContainer.ownedDetails containment
references.

Bug: 427869
Change-Id: I60797d9fd4e7e5885a87ace175d0ae4c6683d2dd
Signed-off-by: Maxime PORHEL <maxime.porhel@obeo.fr>
[427869] Refactor delete representation and representation element
tasks

DeleteSeveralDDiagramElementsTask, DeleteTreeElementsTask and
DeleteTableElementsTask were very similar, they have been merged into
DeleteRepresentationElementsTask. Several issues were detected: each
DeleteXXXElementTask was deleting only the representations of their
corresponding Dialect, a lot of code was duplicated and some unnecessary
treatments were done.

We do not need to create the DeleteDRepresentationTask for
DRepresentation elements nor we need to execute the permission check :
the eDelete/eRemove done in DeleteDRepresentationElementTask will check
this and throw the same LockedInstanceException if required.

The diagram behavior has been kept for the vpElements computation: in
manual refresh compute the DSemanticDecorator to delete in the current
representation. For Tree and Table the previous solution was to delete
only the current DRepresentationElement.

Bug: 427869
Change-Id: I4c002057c8bf99c8d78c7341f1eca24068879b62
Signed-off-by: Maxime PORHEL <maxime.porhel@obeo.fr>