Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 137406 Details for
Bug 277948
Mozilla SWT browser crashes eclipse when closing a popup window
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
patch
patch (text/plain), 2.20 KB, created by
Grant Gayed
on 2009-05-27 15:59:54 EDT
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
Grant Gayed
Created:
2009-05-27 15:59:54 EDT
Size:
2.20 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.swt >Index: Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java,v >retrieving revision 1.132 >diff -u -r1.132 Mozilla.java >--- Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java 6 May 2009 14:54:21 -0000 1.132 >+++ Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java 27 May 2009 19:29:06 -0000 >@@ -2965,19 +2965,35 @@ > } > > int DestroyBrowserWindow () { >- WindowEvent newEvent = new WindowEvent (browser); >- newEvent.display = browser.getDisplay (); >+ final WindowEvent newEvent = new WindowEvent (browser); >+ Display display = browser.getDisplay (); >+ newEvent.display = display; > newEvent.widget = browser; >- for (int i = 0; i < closeWindowListeners.length; i++) { >- closeWindowListeners[i].close (newEvent); >- } > /* >- * Note on Mozilla. The DestroyBrowserWindow notification cannot be cancelled. >- * The browser widget cannot be used after this notification has been received. >- * The application is advised to close the window hosting the browser widget. >- * The browser widget must be disposed in all cases. >- */ >- browser.dispose (); >+ * Bug in mozilla 1.8.x. Under some circumstances the browser being destroyed >+ * is still referenced by mozilla when this callback returns. The workaround >+ * is to delay the destroying of the browser and its window. >+ */ >+ Runnable runnable = new Runnable() { >+ public void run() { >+ if (browser.isDisposed ()) return; >+ for (int i = 0; i < closeWindowListeners.length; i++) { >+ closeWindowListeners[i].close (newEvent); >+ } >+ /* >+ * Note on Mozilla. The DestroyBrowserWindow notification cannot be cancelled. >+ * The browser widget cannot be used after this notification has been received. >+ * The application is advised to close the window hosting the browser widget. >+ * The browser widget must be disposed in all cases. >+ */ >+ browser.dispose (); >+ } >+ }; >+ if (IsPre_1_9 && !IsPre_1_8) { /* 1.8.x */ >+ display.asyncExec (runnable); >+ } else { >+ display.syncExec (runnable); >+ } > return XPCOM.NS_OK; > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 277948
:
137223
|
137227
| 137406