Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndre Weinand2004-11-29 06:32:21 -0500
committerAndre Weinand2004-11-29 06:32:21 -0500
commit2452fe2c78281bdf2744c2e6a1667d16258526b2 (patch)
tree4f2ab95342c2069f6e5b4084e36582bf5347850f /bundles/org.eclipse.compare/compare
parent3f893a5e8c15c0ae957546bac4af125f0ce791e9 (diff)
downloadeclipse.platform.team-2452fe2c78281bdf2744c2e6a1667d16258526b2.tar.gz
eclipse.platform.team-2452fe2c78281bdf2744c2e6a1667d16258526b2.tar.xz
eclipse.platform.team-2452fe2c78281bdf2744c2e6a1667d16258526b2.zip
fixed #79566: NPE when closing JUnit compare viewv20041130
Diffstat (limited to 'bundles/org.eclipse.compare/compare')
-rw-r--r--bundles/org.eclipse.compare/compare/org/eclipse/compare/CompareViewerPane.java11
-rw-r--r--bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/ContentMergeViewer.java2
2 files changed, 10 insertions, 3 deletions
diff --git a/bundles/org.eclipse.compare/compare/org/eclipse/compare/CompareViewerPane.java b/bundles/org.eclipse.compare/compare/org/eclipse/compare/CompareViewerPane.java
index 54f6b00dc..646f99092 100644
--- a/bundles/org.eclipse.compare/compare/org/eclipse/compare/CompareViewerPane.java
+++ b/bundles/org.eclipse.compare/compare/org/eclipse/compare/CompareViewerPane.java
@@ -74,7 +74,16 @@ public class CompareViewerPane extends ViewForm {
};
addMouseListener(ml);
- label.addMouseListener(ml);
+ label.addMouseListener(ml);
+
+ addDisposeListener(new DisposeListener() {
+ public void widgetDisposed(DisposeEvent e) {
+ if (fToolBarManager != null) {
+ fToolBarManager.removeAll();
+ fToolBarManager= null;
+ }
+ }
+ });
}
/**
diff --git a/bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/ContentMergeViewer.java b/bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/ContentMergeViewer.java
index 950d115ee..240e6828c 100644
--- a/bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/ContentMergeViewer.java
+++ b/bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/ContentMergeViewer.java
@@ -852,8 +852,6 @@ public abstract class ContentMergeViewer extends ContentViewer
fHVSashCursor.dispose();
fHVSashCursor= null;
}
-
- CompareViewerPane.clearToolBar(fComposite.getParent());
super.handleDispose(event);
}

Back to the top