Mercurial > hg > release > icedtea6-1.11
changeset 1931:b30c8301d479
Centralized and increased timeouts to give slow-loading applets enough
time to load.
author | Deepak Bhole <dbhole@redhat.com> |
---|---|
date | Mon, 22 Feb 2010 16:54:32 -0500 |
parents | 6571641c60ab |
children | fee30f40652c 6692226bafb6 |
files | ChangeLog plugin/icedteanp/java/sun/applet/PluginAppletViewer.java |
diffstat | 2 files changed, 11 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Sun Feb 21 16:24:11 2010 +0100 +++ b/ChangeLog Mon Feb 22 16:54:32 2010 -0500 @@ -1,3 +1,8 @@ +2010-02-22 Deepak Bhole <dbhole@redhat.com> + + * plugin/icedteanp/java/sun/applet/PluginAppletViewer.java: Centralized + and increased timeouts to give slow-loading applets enough time to load. + 2010-02-21 Xerxes RĂ„nby <xerxes@zafena.se> * ports/hotspot/src/share/vm/shark/sharkCompiler.cpp
--- a/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Sun Feb 21 16:24:11 2010 +0100 +++ b/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Mon Feb 22 16:54:32 2010 -0500 @@ -177,7 +177,7 @@ Applet a; // Wait for panel to come alive - int maxWait = 5000; // wait 5 seconds max for panel to come alive + int maxWait = PluginAppletViewer.APPLET_TIMEOUT; // wait for panel to come alive int wait = 0; while ((panel == null) || (!((NetxPanel) panel).isAlive() && wait < maxWait)) { try { @@ -368,6 +368,8 @@ private long handle = 0; private WindowListener windowEventListener = null; private AppletEventListener appletEventListener = null; + + public static final int APPLET_TIMEOUT = 60000; /** * Null constructor to allow instantiation via newInstance() @@ -616,7 +618,7 @@ if (message.startsWith("handle")) { PluginDebug.debug("handle command waiting for applet to complete loading."); - int maxWait = 10000; // wait 10 seconds max for applet to fully load + int maxWait = APPLET_TIMEOUT; // wait for applet to fully load int wait = 0; while (!status.get(identifier).equals(PAV_INIT_STATUS.INIT_COMPLETE) && (wait < maxWait)) { @@ -663,7 +665,7 @@ if (message.startsWith("width")) { // Wait for panel to come alive - int maxWait = 5000; // wait 5 seconds max for panel to come alive + int maxWait = APPLET_TIMEOUT; // wait for panel to come alive int wait = 0; while (!status.get(identifier).equals(PAV_INIT_STATUS.INIT_COMPLETE) && wait < maxWait) { try { @@ -724,7 +726,7 @@ Object o; // Wait for panel to come alive - int maxWait = 5000; // wait 5 seconds max for panel to come alive + int maxWait = APPLET_TIMEOUT; // wait for panel to come alive int wait = 0; while ((panel == null) || (!((NetxPanel) panel).isAlive() && wait < maxWait)) { try {