diff options
author | Philip Langer | 2015-02-02 09:52:20 +0000 |
---|---|---|
committer | Gerrit Code Review @ Eclipse.org | 2015-02-02 09:52:21 +0000 |
commit | 65f3da469604f76f85fef09e769884d572969a6e (patch) | |
tree | c27cd5a8801b0614c7c5852a0f763b0a961762a2 | |
parent | 9edffec1035f2701c13e60abdf1348360f66a256 (diff) | |
parent | 31610874aebf22d40071810d6f7851076b0d9122 (diff) | |
download | org.eclipse.emf.compare-65f3da469604f76f85fef09e769884d572969a6e.tar.gz org.eclipse.emf.compare-65f3da469604f76f85fef09e769884d572969a6e.tar.xz org.eclipse.emf.compare-65f3da469604f76f85fef09e769884d572969a6e.zip |
Merge "Happy boy-scout: Fixed findbugs warning."
-rw-r--r-- | plugins/org.eclipse.emf.compare.ide.ui/src/org/eclipse/emf/compare/ide/ui/internal/contentmergeviewer/text/EMFCompareTextMergeViewer.java | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/plugins/org.eclipse.emf.compare.ide.ui/src/org/eclipse/emf/compare/ide/ui/internal/contentmergeviewer/text/EMFCompareTextMergeViewer.java b/plugins/org.eclipse.emf.compare.ide.ui/src/org/eclipse/emf/compare/ide/ui/internal/contentmergeviewer/text/EMFCompareTextMergeViewer.java index 5783aa6cb..b70785b34 100644 --- a/plugins/org.eclipse.emf.compare.ide.ui/src/org/eclipse/emf/compare/ide/ui/internal/contentmergeviewer/text/EMFCompareTextMergeViewer.java +++ b/plugins/org.eclipse.emf.compare.ide.ui/src/org/eclipse/emf/compare/ide/ui/internal/contentmergeviewer/text/EMFCompareTextMergeViewer.java @@ -305,16 +305,14 @@ public class EMFCompareTextMergeViewer extends TextMergeViewer implements Comman final Object oldInput = getInput(); if (event.getDocumentEvent() != null && oldInput instanceof CompareInputAdapter) { // When we leave the current input - if (oldInput instanceof CompareInputAdapter) { - final AttributeChange diff = (AttributeChange)((CompareInputAdapter)oldInput) - .getComparisonObject(); - final EAttribute eAttribute = diff.getAttribute(); - final Match match = diff.getMatch(); - final IEqualityHelper equalityHelper = match.getComparison().getEqualityHelper(); - - updateModel(diff, eAttribute, equalityHelper, match.getLeft(), true); - updateModel(diff, eAttribute, equalityHelper, match.getRight(), false); - } + final AttributeChange diff = (AttributeChange)((CompareInputAdapter)oldInput) + .getComparisonObject(); + final EAttribute eAttribute = diff.getAttribute(); + final Match match = diff.getMatch(); + final IEqualityHelper equalityHelper = match.getComparison().getEqualityHelper(); + + updateModel(diff, eAttribute, equalityHelper, match.getLeft(), true); + updateModel(diff, eAttribute, equalityHelper, match.getRight(), false); } } }); |