Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCedric Notot2013-05-31 08:27:30 +0000
committerCedric Notot2013-05-31 08:54:02 +0000
commit00e0a54847c9459df52cce6ffb6ced306d71ef39 (patch)
tree72f8ea6f3c70178599b3ecf6e2c6ab2fa19bbae6
parentc1eda9e7be559403ce8888d7a27b1ce9a7cf0bc8 (diff)
downloadorg.eclipse.emf.compare-00e0a54847c9459df52cce6ffb6ced306d71ef39.tar.gz
org.eclipse.emf.compare-00e0a54847c9459df52cce6ffb6ced306d71ef39.tar.xz
org.eclipse.emf.compare-00e0a54847c9459df52cce6ffb6ced306d71ef39.zip
[406406] Fix Decorators may be shifted in relation to the focused object
-rw-r--r--plugins/org.eclipse.emf.compare.diagram.ide.ui/src/org/eclipse/emf/compare/diagram/ide/ui/internal/contentmergeviewer/diagram/DiagramContentMergeViewer.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/plugins/org.eclipse.emf.compare.diagram.ide.ui/src/org/eclipse/emf/compare/diagram/ide/ui/internal/contentmergeviewer/diagram/DiagramContentMergeViewer.java b/plugins/org.eclipse.emf.compare.diagram.ide.ui/src/org/eclipse/emf/compare/diagram/ide/ui/internal/contentmergeviewer/diagram/DiagramContentMergeViewer.java
index 0646982cd..506b0c340 100644
--- a/plugins/org.eclipse.emf.compare.diagram.ide.ui/src/org/eclipse/emf/compare/diagram/ide/ui/internal/contentmergeviewer/diagram/DiagramContentMergeViewer.java
+++ b/plugins/org.eclipse.emf.compare.diagram.ide.ui/src/org/eclipse/emf/compare/diagram/ide/ui/internal/contentmergeviewer/diagram/DiagramContentMergeViewer.java
@@ -586,7 +586,10 @@ public class DiagramContentMergeViewer extends EMFCompareContentMergeViewer {
Rectangle boundsToTranslate) {
IFigure referenceParentFigure = referenceFigure.getParent();
if (referenceParentFigure != null && referenceFigure != rootReferenceFigure) {
- if (referenceParentFigure.isCoordinateSystem()) {
+ // rootReferenceFigure may be located to (-x,0)... We consider that the root reference is
+ // always (0,0)
+ if (referenceParentFigure.isCoordinateSystem()
+ && referenceParentFigure != rootReferenceFigure) {
boundsToTranslate.x += referenceParentFigure.getBounds().x;
boundsToTranslate.y += referenceParentFigure.getBounds().y;
}

Back to the top