Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGrant Gayed2007-02-07 13:08:17 -0500
committerGrant Gayed2007-02-07 13:08:17 -0500
commitc95c41f1aabc8eeb3fb0764f89486b421ed55bbf (patch)
tree9e7e9e396832f6166fdfb32a36b2684f28d9f567
parente62f9a0fcb4373c20cebd97ebeebc39e92fcbd0e (diff)
downloadeclipse.platform.swt-c95c41f1aabc8eeb3fb0764f89486b421ed55bbf.tar.gz
eclipse.platform.swt-c95c41f1aabc8eeb3fb0764f89486b421ed55bbf.tar.xz
eclipse.platform.swt-c95c41f1aabc8eeb3fb0764f89486b421ed55bbf.zip
171358v3320e
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT Browser/mozilla/org/eclipse/swt/browser/PromptService.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/mozilla/org/eclipse/swt/browser/PromptService.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/mozilla/org/eclipse/swt/browser/PromptService.java
index 0c0bede7f7..9c32223b5c 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/mozilla/org/eclipse/swt/browser/PromptService.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/mozilla/org/eclipse/swt/browser/PromptService.java
@@ -112,6 +112,13 @@ Browser getBrowser(int /*long*/ aDOMWindow) {
nsIWindowWatcher windowWatcher = new nsIWindowWatcher(result[0]);
result[0] = 0;
+ /* the chrome will only be answered for the top-level nsIDOMWindow */
+ nsIDOMWindow window = new nsIDOMWindow (aDOMWindow);
+ rc = window.GetTop (result);
+ if (rc != XPCOM.NS_OK) Browser.error (rc);
+ if (result[0] == 0) Browser.error (XPCOM.NS_NOINTERFACE);
+ aDOMWindow = result[0];
+ result[0] = 0;
rc = windowWatcher.GetChromeForWindow(aDOMWindow, result);
if (rc != XPCOM.NS_OK) Browser.error(rc);
if (result[0] == 0) Browser.error(XPCOM.NS_NOINTERFACE);

Back to the top