Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/uml/org.eclipse.papyrus.diagram.common/src/org/eclipse/papyrus/diagram/common/commands/CommonDeferredCreateConnectionViewCommand.java')
-rw-r--r--plugins/uml/org.eclipse.papyrus.diagram.common/src/org/eclipse/papyrus/diagram/common/commands/CommonDeferredCreateConnectionViewCommand.java21
1 files changed, 2 insertions, 19 deletions
diff --git a/plugins/uml/org.eclipse.papyrus.diagram.common/src/org/eclipse/papyrus/diagram/common/commands/CommonDeferredCreateConnectionViewCommand.java b/plugins/uml/org.eclipse.papyrus.diagram.common/src/org/eclipse/papyrus/diagram/common/commands/CommonDeferredCreateConnectionViewCommand.java
index e5ef6798a5c..bc4bab72c25 100644
--- a/plugins/uml/org.eclipse.papyrus.diagram.common/src/org/eclipse/papyrus/diagram/common/commands/CommonDeferredCreateConnectionViewCommand.java
+++ b/plugins/uml/org.eclipse.papyrus.diagram.common/src/org/eclipse/papyrus/diagram/common/commands/CommonDeferredCreateConnectionViewCommand.java
@@ -109,26 +109,9 @@ public class CommonDeferredCreateConnectionViewCommand extends DeferredCreateCon
@Override
protected CommandResult doExecuteWithResult(IProgressMonitor progressMonitor, IAdaptable info) throws ExecutionException {
Map<?, ?> epRegistry = viewer.getEditPartRegistry();
-
- /**
- * Refresh the registry
- */
- View sourceView = (View)sourceViewAdapter.getAdapter(View.class);
- EObject sourceContainer = sourceView.eContainer();
- IGraphicalEditPart sourceContainerEP = (IGraphicalEditPart)epRegistry.get(sourceContainer);
- View targetView = (View)targetViewAdapter.getAdapter(View.class);
- EObject targetContainer = targetView.eContainer();
- IGraphicalEditPart targetContainerEP = (IGraphicalEditPart)epRegistry.get(targetContainer);
-
- if (sourceContainerEP != null) {
- sourceContainerEP.refresh();
- }
- if (targetContainerEP != null && !targetContainerEP.equals(sourceContainerEP)) {
- targetContainerEP.refresh();
- }
+ IGraphicalEditPart sourceEP = (IGraphicalEditPart)epRegistry.get(sourceViewAdapter.getAdapter(View.class));
+ IGraphicalEditPart targetEP = (IGraphicalEditPart)epRegistry.get(targetViewAdapter.getAdapter(View.class));
- IGraphicalEditPart sourceEP = (IGraphicalEditPart)epRegistry.get(sourceView);
- IGraphicalEditPart targetEP = (IGraphicalEditPart)epRegistry.get(targetView);
/*
* when the source or the target of a link is an other link, the
* previous method returns something like ElementNameEditPart A such

Back to the top