From 5c475d832939f651fa10f4726ef41e1aad86d19a Mon Sep 17 00:00:00 2001
From: kenneth_suter <kenneth_suter@localhost>
Date: Wed, 25 Apr 2007 21:48:40 +0000
Subject: [PATCH] - Addresses issues that was forcing OpenDS.jar to be downloaded during WebStart version of Upgrade. Upgrade now uses the WebStartDownloader to load jars in the background - Fixes UI timing issues with build information being downloaded in a different thread - Introduces a loading panel that is swapped in while panels are in begin draw state to make the UI more responsive when initialization takes a long time
---
opends/src/quicksetup/org/opends/quicksetup/webstart/WebStartDownloader.java | 33 ++++++++++++++++++++++++++++++++-
1 files changed, 32 insertions(+), 1 deletions(-)
diff --git a/opends/src/quicksetup/org/opends/quicksetup/installer/webstart/WebStartDownloader.java b/opends/src/quicksetup/org/opends/quicksetup/webstart/WebStartDownloader.java
similarity index 93%
rename from opends/src/quicksetup/org/opends/quicksetup/installer/webstart/WebStartDownloader.java
rename to opends/src/quicksetup/org/opends/quicksetup/webstart/WebStartDownloader.java
index 9e9b706..41ade92 100644
--- a/opends/src/quicksetup/org/opends/quicksetup/installer/webstart/WebStartDownloader.java
+++ b/opends/src/quicksetup/org/opends/quicksetup/webstart/WebStartDownloader.java
@@ -25,7 +25,7 @@
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.quicksetup.installer.webstart;
+package org.opends.quicksetup.webstart;
import java.io.IOException;
import java.net.MalformedURLException;
@@ -69,6 +69,8 @@
private Status status = Status.DOWNLOADING;
+ private String summary = null;
+
/**
* This enumeration contains the different Status on which
* the dowloading process of the jars can be.
@@ -91,6 +93,13 @@
}
/**
+ * Creates a default instance.
+ */
+ public WebStartDownloader() {
+ this.summary = getMsg("downloading");
+ }
+
+ /**
* Starts the downloading of the jar files. If forceDownload is set to
* <CODE>true</CODE> the files will be re-downloaded even if they already
* are on cache.
@@ -147,6 +156,22 @@
}
/**
+ * Gets a summary message of the downloader's current progress.
+ * @return String for showing the user progress
+ */
+ public String getSummary() {
+ return this.summary;
+ }
+
+ /**
+ * Sets a summary message of the downloader's current progress.
+ * @param summary String for showing the user progress
+ */
+ public void setSummary(String summary) {
+ this.summary = summary;
+ }
+
+ /**
* Returns <CODE>true</CODE> if the install is finished and
* <CODE>false</CODE> otherwise.
* @return <CODE>true</CODE> if the install is finished and
@@ -421,4 +446,10 @@
{
return ResourceProvider.getInstance().getMsg(key, args);
}
+
+ private String getMsg(String key)
+ {
+ return ResourceProvider.getInstance().getMsg(key);
+ }
+
}
--
Gitblit v1.10.0