Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDani Megert2002-06-06 10:33:17 +0000
committerDani Megert2002-06-06 10:33:17 +0000
commit5e55e524940fc8b7fc45f589fddfde7c20b88e7c (patch)
treecde698ae675713ed1439dedf2f708610eaecc2a3
parentbbb50aecd19124ef3440893a8cd0fb984fa74c91 (diff)
downloadeclipse.platform.text-5e55e524940fc8b7fc45f589fddfde7c20b88e7c.tar.gz
eclipse.platform.text-5e55e524940fc8b7fc45f589fddfde7c20b88e7c.tar.xz
eclipse.platform.text-5e55e524940fc8b7fc45f589fddfde7c20b88e7c.zip
Fixed F3 bug: 18622: 20020601build. Search dialog does not close after file or help search.
Reviewed with AK
-rw-r--r--org.eclipse.search/search/org/eclipse/search/internal/ui/SearchManager.java12
-rw-r--r--org.eclipse.search/search/org/eclipse/search/internal/ui/SearchResultViewer.java2
2 files changed, 8 insertions, 6 deletions
diff --git a/org.eclipse.search/search/org/eclipse/search/internal/ui/SearchManager.java b/org.eclipse.search/search/org/eclipse/search/internal/ui/SearchManager.java
index ec33a4ee7..7d1b908c5 100644
--- a/org.eclipse.search/search/org/eclipse/search/internal/ui/SearchManager.java
+++ b/org.eclipse.search/search/org/eclipse/search/internal/ui/SearchManager.java
@@ -242,18 +242,17 @@ public class SearchManager implements IResourceChangeListener {
final Viewer visibleViewer= ((SearchResultView)SearchPlugin.getSearchResultView()).getViewer();
while (iter.hasNext()) {
final SearchResultViewer viewer= (SearchResultViewer)iter.next();
- viewer.setGotoMarkerAction(search.getGotoMarkerAction());
- if (search.getContextMenuContributor() != null)
- viewer.setContextMenuTarget(search.getContextMenuContributor());
display.syncExec(new Runnable() {
public void run() {
if (previousSearch != null && viewer == visibleViewer)
previousSearch.setSelection(viewer.getSelection());
viewer.setPageId(search.getPageId());
+ viewer.setGotoMarkerAction(search.getGotoMarkerAction());
+ viewer.setContextMenuTarget(search.getContextMenuContributor());
+ viewer.setActionGroupFactory(null);
viewer.setInput(getCurrentResults());
- viewer.setSelection(fCurrentSearch.getSelection(), true);
- viewer.setSelection(new StructuredSelection(getCurrentResults().get(0)));
viewer.setActionGroupFactory(search.getActionGroupFactory());
+ viewer.setSelection(fCurrentSearch.getSelection(), true);
}
});
}
@@ -399,8 +398,9 @@ public class SearchManager implements IResourceChangeListener {
while (iter.hasNext()) {
SearchResultViewer viewer= (SearchResultViewer)iter.next();
viewer.setPageId(search.getPageId());
- viewer.setContextMenuTarget(search.getContextMenuContributor());
viewer.setGotoMarkerAction(search.getGotoMarkerAction());
+ viewer.setContextMenuTarget(search.getContextMenuContributor());
+ viewer.setActionGroupFactory(null);
viewer.setInput(getCurrentResults());
viewer.setActionGroupFactory(search.getActionGroupFactory());
}
diff --git a/org.eclipse.search/search/org/eclipse/search/internal/ui/SearchResultViewer.java b/org.eclipse.search/search/org/eclipse/search/internal/ui/SearchResultViewer.java
index f42d6e265..372b06490 100644
--- a/org.eclipse.search/search/org/eclipse/search/internal/ui/SearchResultViewer.java
+++ b/org.eclipse.search/search/org/eclipse/search/internal/ui/SearchResultViewer.java
@@ -566,6 +566,8 @@ public class SearchResultViewer extends TableViewer {
* Handle remove all.
*/
protected void handleRemoveAll() {
+ setContextMenuTarget(null);
+ setActionGroupFactory(null);
setInput(null);
}

Back to the top