Minor tweaks.
This commit is contained in:
@@ -241,16 +241,15 @@ public class GetdownApplet extends JApplet
|
|||||||
// when run from an applet, we install to the user's home directory
|
// when run from an applet, we install to the user's home directory
|
||||||
String root;
|
String root;
|
||||||
if (RunAnywhere.isWindows()) {
|
if (RunAnywhere.isWindows()) {
|
||||||
String verStr = System.getProperty("os.version");
|
|
||||||
root = "Application Data";
|
root = "Application Data";
|
||||||
|
String verStr = System.getProperty("os.version");
|
||||||
try {
|
try {
|
||||||
float version = Float.parseFloat(verStr);
|
if (Float.parseFloat(verStr) >= 6.0f) {
|
||||||
if (version >= 6.0) {
|
|
||||||
// Vista makes us write it here.... Yay.
|
// Vista makes us write it here.... Yay.
|
||||||
root = "AppData" + File.separator + "LocalLow";
|
root = "AppData" + File.separator + "LocalLow";
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
Log.warning("Couldn't parse OS version: " +verStr);
|
Log.warning("Couldn't parse OS version [vers=" + verStr + ", error=" + e + "].");
|
||||||
}
|
}
|
||||||
} else if (RunAnywhere.isMacOS()) {
|
} else if (RunAnywhere.isMacOS()) {
|
||||||
root = "Library" + File.separator + "Application Support";
|
root = "Library" + File.separator + "Application Support";
|
||||||
|
|||||||
Reference in New Issue
Block a user