import javax.swing.Timer;
import javax.swing.ToolTipManager;
+import net.sf.openrocket.arch.SystemInfo;
+import net.sf.openrocket.arch.SystemInfo.Platform;
import net.sf.openrocket.communication.UpdateInfo;
import net.sf.openrocket.communication.UpdateInfoRetriever;
import net.sf.openrocket.database.ComponentPresetDatabase;
VersionHelper.checkVersion();
VersionHelper.checkOpenJDK();
+ // If running on a MAC set up OSX UI Elements.
+ if ( SystemInfo.getPlatform() == Platform.MAC_OS ){
+ OSXStartup.setupOSX();
+ }
+
// Run the actual startup method in the EDT since it can use progress dialogs etc.
log.info("Moving startup to EDT");
SwingUtilities.invokeAndWait(new Runnable() {
// Load motors etc.
log.info("Loading databases");
- ConcurrentLoadingThrustCurveMotorSetDatabase motorLoader = new ConcurrentLoadingThrustCurveMotorSetDatabase(THRUSTCURVE_DIRECTORY);
- motorLoader.startLoading();
- Application.setMotorSetDatabase(motorLoader);
-
+ loadMotor();
+
Databases.fakeMethod();
try {
}
+ /**
+ * this method is useful for the python bindings.
+ */
+ public static void loadMotor() {
+ ConcurrentLoadingThrustCurveMotorSetDatabase motorLoader = new ConcurrentLoadingThrustCurveMotorSetDatabase(THRUSTCURVE_DIRECTORY);
+ motorLoader.startLoading();
+ Application.setMotorSetDatabase(motorLoader);
+ }
/**
* Check that the JRE is not running headless.