Cleaned up some dodgy code when initially prompting for FTL's location
This commit is contained in:
parent
5970fbcc66
commit
3646de2aec
3 changed files with 29 additions and 17 deletions
2
pom.xml
2
pom.xml
|
@ -2,7 +2,7 @@
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<groupId>net.vhati.modmanager</groupId>
|
<groupId>net.vhati.modmanager</groupId>
|
||||||
<artifactId>ftl-mod-manager</artifactId>
|
<artifactId>ftl-mod-manager</artifactId>
|
||||||
<version>1.3</version>
|
<version>1.4</version>
|
||||||
<name>Slipstream Mod Manager</name>
|
<name>Slipstream Mod Manager</name>
|
||||||
|
|
||||||
<!-- Determined by mvn versions:display-plugin-updates -->
|
<!-- Determined by mvn versions:display-plugin-updates -->
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
Changelog
|
Changelog
|
||||||
|
|
||||||
|
1.4:
|
||||||
|
- Cleaned up some dodgy code when initially prompting for FTL's location
|
||||||
|
|
||||||
1.3:
|
1.3:
|
||||||
- Added "Return FTL to an unmodded state before switching to a new version"
|
- Added "Return FTL to an unmodded state before switching to a new version"
|
||||||
- Fixed advanced find tags' panic arg (was "true" all the time)
|
- Fixed advanced find tags' panic arg (was "true" all the time)
|
||||||
|
|
|
@ -25,7 +25,7 @@ public class FTLModManager {
|
||||||
private static final Logger log = LogManager.getLogger(FTLModManager.class);
|
private static final Logger log = LogManager.getLogger(FTLModManager.class);
|
||||||
|
|
||||||
public static final String APP_NAME = "Slipstream Mod Manager";
|
public static final String APP_NAME = "Slipstream Mod Manager";
|
||||||
public static final ComparableVersion APP_VERSION = new ComparableVersion( "1.3" );
|
public static final ComparableVersion APP_VERSION = new ComparableVersion( "1.4" );
|
||||||
public static final String APP_URL = "http://www.ftlgame.com/forum/viewtopic.php?f=12&t=17102";
|
public static final String APP_URL = "http://www.ftlgame.com/forum/viewtopic.php?f=12&t=17102";
|
||||||
public static final String APP_AUTHOR = "Vhati";
|
public static final String APP_AUTHOR = "Vhati";
|
||||||
|
|
||||||
|
@ -33,6 +33,20 @@ public class FTLModManager {
|
||||||
public static void main( String[] args ) {
|
public static void main( String[] args ) {
|
||||||
if ( args.length > 0 ) SlipstreamCLI.main( args );
|
if ( args.length > 0 ) SlipstreamCLI.main( args );
|
||||||
|
|
||||||
|
|
||||||
|
// Ensure all popups are triggered from the event dispatch thread.
|
||||||
|
|
||||||
|
SwingUtilities.invokeLater(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
guiInit();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private static void guiInit() {
|
||||||
|
|
||||||
log.debug( String.format( "%s v%s", APP_NAME, APP_VERSION ) );
|
log.debug( String.format( "%s v%s", APP_NAME, APP_VERSION ) );
|
||||||
log.debug( String.format( "%s %s", System.getProperty("os.name"), System.getProperty("os.version") ) );
|
log.debug( String.format( "%s %s", System.getProperty("os.name"), System.getProperty("os.version") ) );
|
||||||
log.debug( String.format( "%s, %s, %s", System.getProperty("java.vm.name"), System.getProperty("java.version"), System.getProperty("os.arch") ) );
|
log.debug( String.format( "%s, %s, %s", System.getProperty("java.vm.name"), System.getProperty("java.version"), System.getProperty("os.arch") ) );
|
||||||
|
@ -156,7 +170,7 @@ public class FTLModManager {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
final SlipstreamConfig appConfig = new SlipstreamConfig( config, configFile );
|
SlipstreamConfig appConfig = new SlipstreamConfig( config, configFile );
|
||||||
if ( writeConfig ) {
|
if ( writeConfig ) {
|
||||||
try {
|
try {
|
||||||
appConfig.writeConfig();
|
appConfig.writeConfig();
|
||||||
|
@ -168,10 +182,7 @@ public class FTLModManager {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Create the GUI.
|
// Create the main window.
|
||||||
SwingUtilities.invokeLater(new Runnable() {
|
|
||||||
@Override
|
|
||||||
public void run() {
|
|
||||||
try {
|
try {
|
||||||
ManagerFrame frame = new ManagerFrame( appConfig, APP_NAME, APP_VERSION, APP_URL, APP_AUTHOR );
|
ManagerFrame frame = new ManagerFrame( appConfig, APP_NAME, APP_VERSION, APP_URL, APP_AUTHOR );
|
||||||
frame.init();
|
frame.init();
|
||||||
|
@ -181,8 +192,6 @@ public class FTLModManager {
|
||||||
System.exit(1);
|
System.exit(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue