Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas FAUVERGUE2019-06-12 13:41:58 +0000
committerNicolas FAUVERGUE2019-06-17 11:24:44 +0000
commit1dc89045f2a3acd3b70a0912f1638c60f69255cc (patch)
tree6ed8a46e89dff4844c6249e849f192897d32c3b6 /plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.activity/custom-src/org/eclipse/papyrus
parentb7f513de85288011267f83c88389254745f03ae0 (diff)
downloadorg.eclipse.papyrus-1dc89045f2a3acd3b70a0912f1638c60f69255cc.tar.gz
org.eclipse.papyrus-1dc89045f2a3acd3b70a0912f1638c60f69255cc.tar.xz
org.eclipse.papyrus-1dc89045f2a3acd3b70a0912f1638c60f69255cc.zip
Bug 533248: [Activity Diagram] Moving an activityNode between
ActivityPartitions using drag&drop does not update InPartition and Node properties correctly The move out/in of ActivityPartition was managed but the move from ActivityPartition to another one not. So this patch do it. Change-Id: I1f002f99f289829e62ac6de6e49991d68b60101e Signed-off-by: Nicolas FAUVERGUE <nicolas.fauvergue@cea.fr>
Diffstat (limited to 'plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.activity/custom-src/org/eclipse/papyrus')
-rw-r--r--plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.activity/custom-src/org/eclipse/papyrus/uml/diagram/activity/edit/policies/ActivityCompartmentCreationEditPolicy.java16
1 files changed, 14 insertions, 2 deletions
diff --git a/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.activity/custom-src/org/eclipse/papyrus/uml/diagram/activity/edit/policies/ActivityCompartmentCreationEditPolicy.java b/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.activity/custom-src/org/eclipse/papyrus/uml/diagram/activity/edit/policies/ActivityCompartmentCreationEditPolicy.java
index 7a7b93785ca..7c5a87fb49b 100644
--- a/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.activity/custom-src/org/eclipse/papyrus/uml/diagram/activity/edit/policies/ActivityCompartmentCreationEditPolicy.java
+++ b/plugins/uml/diagram/org.eclipse.papyrus.uml.diagram.activity/custom-src/org/eclipse/papyrus/uml/diagram/activity/edit/policies/ActivityCompartmentCreationEditPolicy.java
@@ -1,6 +1,6 @@
/*****************************************************************************
* Copyright (c) 2015 CEA LIST and others.
- *
+ *
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
* which accompanies this distribution, and is available at
@@ -10,7 +10,7 @@
*
* Contributors:
* CEA LIST - Initial API and implementation
- *
+ *
*****************************************************************************/
package org.eclipse.papyrus.uml.diagram.activity.edit.policies;
@@ -69,9 +69,21 @@ public class ActivityCompartmentCreationEditPolicy extends DefaultCreationEditPo
EObject currentParentSemantic = ((IGraphicalEditPart) gep.getParent()).resolveSemanticElement();
if (currentParentSemantic instanceof ActivityPartition) {
req.setParameter(ActivityNodeHelper.OUT_FROM_PARTITION, currentParentSemantic);
+ if (context instanceof ActivityPartition) {
+ req.setParameter(ActivityNodeHelper.IN_PARTITION, context);
+ }
+ if (context instanceof InterruptibleActivityRegion) {
+ req.setParameter(ActivityNodeHelper.IN_INTERRUPTIBLE_ACTIVITY_REGION, context);
+ }
}
if (currentParentSemantic instanceof InterruptibleActivityRegion) {
req.setParameter(ActivityNodeHelper.OUT_FROM_INTERRUPTIBLE_REGION, currentParentSemantic);
+ if (context instanceof ActivityPartition) {
+ req.setParameter(ActivityNodeHelper.IN_PARTITION, context);
+ }
+ if (context instanceof InterruptibleActivityRegion) {
+ req.setParameter(ActivityNodeHelper.IN_INTERRUPTIBLE_ACTIVITY_REGION, context);
+ }
}
Command moveSemanticCmd = getHost().getCommand(new EditCommandRequestWrapper(req));

Back to the top