Explorar el Código

fix some non issues

tags/0.6.3m1rc1
Gregory Holmes hace 15 años
padre
commit
e2138a5172
Se han modificado 1 ficheros con 18 adiciones y 15 borrados
  1. 18
    15
      src/com/dmdirc/installer/InstallerListener.java

+ 18
- 15
src/com/dmdirc/installer/InstallerListener.java Ver fichero

64
         if ("Install".equals(step.getStepName())) {
64
         if ("Install".equals(step.getStepName())) {
65
             installerToBeDisplayed(step);
65
             installerToBeDisplayed(step);
66
         } else if ("Confirm".equals(step.getStepName())) {
66
         } else if ("Confirm".equals(step.getStepName())) {
67
-            confirmToBeDisplayed((TextStep) step);
67
+            confirmToBeDisplayed(step);
68
         }
68
         }
69
     }
69
     }
70
 
70
 
82
         Main.getInstaller().start();
82
         Main.getInstaller().start();
83
     }
83
     }
84
 
84
 
85
-    private void confirmToBeDisplayed(final TextStep step) {
85
+    private void confirmToBeDisplayed(final Step step) {
86
         String shortcutText = "";
86
         String shortcutText = "";
87
 
87
 
88
         final Settings settings = (Settings) Main.getWizardFrame().getStep(1);
88
         final Settings settings = (Settings) Main.getWizardFrame().getStep(1);
113
         final String installLocation = settings.getInstallLocation();
113
         final String installLocation = settings.getInstallLocation();
114
 
114
 
115
 
115
 
116
-        if (installLocation.isEmpty()) {
117
-            step.setText(
118
-                    "You have chosen an invalid install location\n\n" +
119
-                    "Please press the \"Previous\" button to go back and correct it.");
120
-            Main.getWizardFrame().enableNextStep(false);
121
-        } else {
122
-            step.setText(
123
-                    "Please review your chosen settings:\n\n" +
124
-                    " - Install Location:\n" + "    " + installLocation +
125
-                    "\n" + shortcutText + "\n" +
126
-                    "If you wish to change any of these settings, press the \"Previous\" button," +
127
-                    "otherwise click \"Next\" to begin the installation");
128
-            Main.getWizardFrame().enableNextStep(true);
116
+        if (step instanceof TextStep) {
117
+            final TextStep textStep = (TextStep) step;
118
+            if (installLocation.isEmpty()) {
119
+                textStep.setText(
120
+                        "You have chosen an invalid install location\n\n" +
121
+                        "Please press the \"Previous\" button to go back and correct it.");
122
+               Main.getWizardFrame().enableNextStep(false);
123
+            } else {
124
+                textStep.setText(
125
+                        "Please review your chosen settings:\n\n" +
126
+                        " - Install Location:\n" + "    " + installLocation +
127
+                        "\n" + shortcutText + "\n" + "If you wish to change " +
128
+                        "any of these settings, press the \"Previous\" " +
129
+                        "button, otherwise click \"Next\" to begin the installation");
130
+                Main.getWizardFrame().enableNextStep(true);
131
+           }
129
         }
132
         }
130
     }
133
     }
131
 }
134
 }

Loading…
Cancelar
Guardar