From 6292beaede500c125091a84263ed7cda454ba299 Mon Sep 17 00:00:00 2001
From: Gaetan Boismal <gaetan.boismal@forgerock.com>
Date: Wed, 21 Oct 2015 16:05:43 +0000
Subject: [PATCH] OPENDJ-2348 PR-96 Remove webstart and netscape support
---
opendj-server-legacy/src/main/java/org/opends/quicksetup/installer/ui/InstallReviewPanel.java | 39 ++++-----------------------------------
1 files changed, 4 insertions(+), 35 deletions(-)
diff --git a/opendj-server-legacy/src/main/java/org/opends/quicksetup/installer/ui/InstallReviewPanel.java b/opendj-server-legacy/src/main/java/org/opends/quicksetup/installer/ui/InstallReviewPanel.java
index 3fe28e2..968ea43 100644
--- a/opendj-server-legacy/src/main/java/org/opends/quicksetup/installer/ui/InstallReviewPanel.java
+++ b/opendj-server-legacy/src/main/java/org/opends/quicksetup/installer/ui/InstallReviewPanel.java
@@ -82,8 +82,6 @@
private static final long serialVersionUID = -7356174829193265699L;
- private final boolean displayServerLocation;
-
private final HashMap<FieldName, JLabel> hmLabels = new HashMap<>();
private final HashMap<FieldName, JTextComponent> hmFields = new HashMap<>();
private JPanel bottomComponent;
@@ -110,7 +108,6 @@
public InstallReviewPanel(GuiApplication application)
{
super(application);
- this.displayServerLocation = isWebStart();
populateLabelAndFieldsMap();
}
@@ -118,10 +115,6 @@
@Override
public void beginDisplay(UserData userData)
{
- if (displayServerLocation)
- {
- setFieldValue(FieldName.SERVER_LOCATION, userData.getServerLocation());
- }
setFieldValue(FieldName.HOST_NAME, userData.getHostName());
setFieldValue(FieldName.SERVER_PORT, Integer.toString(userData.getServerPort()));
setFieldValue(FieldName.ADMIN_CONNECTOR_PORT, Integer.toString(userData.getAdminConnectorPort()));
@@ -278,15 +271,6 @@
{
final HashMap<FieldName, LabelFieldDescriptor> hm = new HashMap<>();
- if (displayServerLocation)
- {
- hm.put(FieldName.SERVER_LOCATION, new LabelFieldDescriptor(
- INFO_SERVER_LOCATION_LABEL.get(),
- INFO_SERVER_LOCATION_RELATIVE_TOOLTIP.get(),
- LabelFieldDescriptor.FieldType.READ_ONLY,
- LabelFieldDescriptor.LabelType.PRIMARY, 0));
- }
-
hm.put(FieldName.HOST_NAME, new LabelFieldDescriptor(
INFO_HOST_NAME_LABEL.get(),
INFO_HOST_NAME_TOOLTIP.get(),
@@ -506,11 +490,6 @@
final GridBagConstraints gbc = new GridBagConstraints();
final List<FieldName> fieldNames = new LinkedList<>();
- if (displayServerLocation)
- {
- fieldNames.add(FieldName.SERVER_LOCATION);
- }
-
fieldNames.addAll(Arrays.asList(
new FieldName[] {
FieldName.HOST_NAME, FieldName.SERVER_PORT,
@@ -780,13 +759,13 @@
if (linesToAdd.size() == 1)
{
- final String arg0 = getJavaPropertiesFilePath(userData);
+ final String arg0 = getJavaPropertiesFilePath();
final String arg1 = linesToAdd.get(0);
sb.append(formatter.getFormattedProgress(INFO_EDIT_JAVA_PROPERTIES_LINE.get(arg0, arg1)));
}
else if (linesToAdd.size() > 1)
{
- final String arg0 = getJavaPropertiesFilePath(userData);
+ final String arg0 = getJavaPropertiesFilePath();
final String arg1 = joinAsString(Constants.LINE_SEPARATOR, linesToAdd);
sb.append(formatter.getFormattedProgress(INFO_EDIT_JAVA_PROPERTIES_LINES.get(arg0, arg1)));
}
@@ -799,19 +778,9 @@
return scriptName + ".java-args";
}
- private String getJavaPropertiesFilePath(UserData userData)
+ private String getJavaPropertiesFilePath()
{
- String path;
- if (isWebStart())
- {
- path = userData.getServerLocation();
- }
- else
- {
- path = Utils.getInstallPathFromClasspath();
- path = Utils.getInstancePathFromInstallPath(path);
- }
-
+ final String path = Utils.getInstancePathFromInstallPath(Utils.getInstallPathFromClasspath());
return getPath(getPath(path, Installation.CONFIG_PATH_RELATIVE), Installation.DEFAULT_JAVA_PROPERTIES_FILE);
}
--
Gitblit v1.10.0