summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcaustin2011-11-29 14:27:52 (EST)
committercaustin2011-11-29 14:27:52 (EST)
commit6e608e3f86e13b043ba22affc3a41b369ffb5cab (patch)
tree7842c9725c69e88ef75031c10f907f5a59f978a1
parentebaa5c26e60b0a64d63de4c72ea7cfda8f4edc02 (diff)
downloadeclipse.platform.ua-6e608e3f86e13b043ba22affc3a41b369ffb5cab.zip
eclipse.platform.ua-6e608e3f86e13b043ba22affc3a41b369ffb5cab.tar.gz
eclipse.platform.ua-6e608e3f86e13b043ba22affc3a41b369ffb5cab.tar.bz2
Bug 361118 - Eclipse crashes in ieframe.dll when repeatedly opening the
same link in an external browser
-rw-r--r--org.eclipse.help.ui/src/org/eclipse/help/ui/internal/browser/embedded/EmbeddedBrowser.java31
1 files changed, 14 insertions, 17 deletions
diff --git a/org.eclipse.help.ui/src/org/eclipse/help/ui/internal/browser/embedded/EmbeddedBrowser.java b/org.eclipse.help.ui/src/org/eclipse/help/ui/internal/browser/embedded/EmbeddedBrowser.java
index e00c7b4..ef4ad36 100644
--- a/org.eclipse.help.ui/src/org/eclipse/help/ui/internal/browser/embedded/EmbeddedBrowser.java
+++ b/org.eclipse.help.ui/src/org/eclipse/help/ui/internal/browser/embedded/EmbeddedBrowser.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2010 IBM Corporation and others.
+ * Copyright (c) 2000, 2011 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -69,7 +69,6 @@ public class EmbeddedBrowser {
private static String initialTitle = getWindowTitle();
private Shell shell;
private Browser browser;
- private Browser externalBrowser;
private Composite statusBar;
private Label statusBarText;
private Label statusBarSeparator;
@@ -380,22 +379,20 @@ public class EmbeddedBrowser {
shell.forceActive();
}
private void displayURLExternal(WindowEvent e) {
- if (externalBrowser == null) {
- final Shell externalShell = new Shell(shell, SWT.NONE);
- externalBrowser = new Browser(externalShell, SWT.NONE);
- externalBrowser.addLocationListener(new LocationAdapter() {
- public void changing(final LocationEvent e) {
- e.doit = false;
- try {
- BaseHelpSystem.getHelpBrowser(true).displayURL(e.location);
- }
- catch (Throwable t) {
- String msg = "Error opening external Web browser"; //$NON-NLS-1$
- HelpUIPlugin.logError(msg, t);
- }
+ final Shell externalShell = new Shell(shell, SWT.NONE);
+ Browser externalBrowser = new Browser(externalShell, SWT.NONE);
+ externalBrowser.addLocationListener(new LocationAdapter() {
+ public void changing(final LocationEvent e) {
+ e.doit = false;
+ try {
+ BaseHelpSystem.getHelpBrowser(true).displayURL(e.location);
}
- });
- }
+ catch (Throwable t) {
+ String msg = "Error opening external Web browser"; //$NON-NLS-1$
+ HelpUIPlugin.logError(msg, t);
+ }
+ }
+ });
e.browser = externalBrowser;
}
public boolean isDisposed() {