Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndre Weinand2004-11-29 11:32:21 +0000
committerAndre Weinand2004-11-29 11:32:21 +0000
commit2452fe2c78281bdf2744c2e6a1667d16258526b2 (patch)
tree4f2ab95342c2069f6e5b4084e36582bf5347850f
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
-rw-r--r--bundles/org.eclipse.compare/buildnotes_compare.html1
-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
-rw-r--r--bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html1
-rw-r--r--bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/CompareViewerPane.java11
-rw-r--r--bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/ContentMergeViewer.java2
6 files changed, 22 insertions, 6 deletions
diff --git a/bundles/org.eclipse.compare/buildnotes_compare.html b/bundles/org.eclipse.compare/buildnotes_compare.html
index 2c8339c32..f4049a287 100644
--- a/bundles/org.eclipse.compare/buildnotes_compare.html
+++ b/bundles/org.eclipse.compare/buildnotes_compare.html
@@ -16,6 +16,7 @@ Eclipse Build Input November 30th 2004
<h2>Problem reports fixed</h2>
<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=79414">79414</a>: states with same time stamps may appear in the wrong order<br>
+<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=79566">79566</a>: NPE when closing JUnit compare view<br>
<h1><hr WIDTH="100%"></h1>
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);
}
diff --git a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html
index 2c8339c32..f4049a287 100644
--- a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html
+++ b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html
@@ -16,6 +16,7 @@ Eclipse Build Input November 30th 2004
<h2>Problem reports fixed</h2>
<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=79414">79414</a>: states with same time stamps may appear in the wrong order<br>
+<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=79566">79566</a>: NPE when closing JUnit compare view<br>
<h1><hr WIDTH="100%"></h1>
diff --git a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/CompareViewerPane.java b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/CompareViewerPane.java
index 54f6b00dc..646f99092 100644
--- a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/CompareViewerPane.java
+++ b/bundles/org.eclipse.compare/plugins/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/plugins/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/ContentMergeViewer.java b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/ContentMergeViewer.java
index 950d115ee..240e6828c 100644
--- a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/ContentMergeViewer.java
+++ b/bundles/org.eclipse.compare/plugins/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