1.1 --- a/installer/components/products/glassfish-mod/src/org/netbeans/installer/products/glassfish/mod/wizard/panels/GlassFishPanel.java Wed Apr 03 11:13:05 2013 +0200
1.2 +++ b/installer/components/products/glassfish-mod/src/org/netbeans/installer/products/glassfish/mod/wizard/panels/GlassFishPanel.java Wed Apr 03 19:11:14 2013 +0200
1.3 @@ -151,16 +151,6 @@
1.4
1.5 jdkLocationPanel.initialize();
1.6
1.7 - //This makes it possible to perform silent installation with emptry state files
1.8 - //that means that JDK_LOCATION_PROPERTY property is explicitely set to the first location
1.9 - //that fits the requirements
1.10 - //TODO: Investigate the prons&cons and side affects of moving
1.11 - //this code to the end of JdkLocationPanel.initialize() method
1.12 - File jdkLocation = jdkLocationPanel.getSelectedLocation();
1.13 - if(jdkLocation!=null && !jdkLocation.getPath().equals(StringUtils.EMPTY_STRING)) {
1.14 - jdkLocationPanel.setLocation(jdkLocation);
1.15 - }
1.16 -
1.17 getWizard().setProperty(JdkLocationPanel.JDK_LOCATION_PROPERTY, jdkSelectedInGF == null ? "" : jdkSelectedInGF); // NOI18N
1.18 }
1.19
1.20 @@ -340,7 +330,8 @@
1.21 private String getNeedJava7Warning() {
1.22 String warningMessage = null;
1.23 if (getWarningMessage() == null) {
1.24 - if (JavaUtils.criticalLowVersion.newerThan(JavaUtils.getVersion(panel.getJdkLocationPanel().getSelectedLocation()))) {
1.25 + if (JavaUtils.criticalLowVersion.newerThan(
1.26 + JavaUtils.getVersion(new File(jdkLocationField.getText())))) {
1.27 warningMessage = StringUtils.format(
1.28 panel.getProperty(WARNING_JDK_NOT_RECOMMENDED_VERSION),
1.29 panel.jdkLocationPanel.getProperty(JdkLocationPanel.JAVA_DOWNLOAD_PAGE_PROPERTY));