Mercurial > hg > release > icedtea-web-1.6
changeset 244:c73d453f811b
Call dispose() from swing thread when applet is closed.
Do not stop applet threadgroup on exit.
author | Deepak Bhole <dbhole@redhat.com> |
---|---|
date | Fri, 27 May 2011 17:27:55 -0400 |
parents | 9cf54e1ace44 |
children | 1d10dbc851d7 |
files | ChangeLog plugin/icedteanp/java/sun/applet/PluginAppletViewer.java |
diffstat | 2 files changed, 14 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Fri May 27 17:03:25 2011 -0400 +++ b/ChangeLog Fri May 27 17:27:55 2011 -0400 @@ -1,3 +1,9 @@ +2011-05-27 Deepak Bhole <dbhole@redhat.com> + + * plugin/icedteanp/java/sun/applet/PluginAppletViewer.java + (appletClose): Call dispose from the swing thread. Also, don't try to stop + the threadgroup. + 2011-05-27 Deepak Bhole <dbhole@redhat.com> * Backed out 0256de6a4bf6
--- a/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Fri May 27 17:03:25 2011 -0400 +++ b/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Fri May 27 17:27:55 2011 -0400 @@ -1625,10 +1625,15 @@ appletShutdown(p); appletPanels.removeElement(p); - dispose(); - if (tg.activeCount() > 0) - tg.stop(); + try { + SwingUtilities.invokeAndWait(new Runnable() { + public void run() { + dispose(); + } + }); + } catch (Exception e) { // ignore, we are just disposing it + } if (countApplets() == 0) { appletSystemExit();