Changeset 33 in tmcsimulator for trunk/src/tmcsim/simulationmanager
- Timestamp:
- 04/29/2016 12:55:04 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/tmcsim/simulationmanager/SimulationManager.java
r14 r33 9 9 import java.util.logging.Level; 10 10 import java.util.logging.Logger; 11 11 12 import javax.swing.JOptionPane; 12 13 import javax.swing.UIManager; 14 13 15 import tmcsim.common.CADEnums.PARAMICS_STATUS; 14 16 import tmcsim.common.SimulationException; … … 45 47 { 46 48 47 /** 49 private static final String CONFIG_FILE_NAME = "sim_manager_config.properties"; 50 /** 48 51 * Error logger. 49 52 */ … … 193 196 * @param args Command line arguments. 194 197 */ 195 static public void main(String[] args) 196 { 197 //System.setProperty("SIM_MGR_PROPERTIES", "config/sim_manager_config.properties"); 198 static public void main(String[] args) { 198 199 //System.setProperty("swing.defaultlaf", "com.sun.java.swing.plaf.nimbus.NimbusLookAndFeel"); 199 200 try 201 { 202 if (System.getProperty("SIM_MGR_PROPERTIES") != null) 203 { 204 UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); 205 206 new SimulationManager(System.getProperty("SIM_MGR_PROPERTIES")); 207 } else 208 { 209 throw new Exception("SIM_MGR_PROPERTIES system property not defined."); 210 } 211 } catch (Exception e) 212 { 200 if(System.getProperty("CONFIG_DIR") == null){ 201 System.setProperty("CONFIG_DIR", "config"); 202 } 203 204 try { 205 UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); 206 new SimulationManager(System.getProperty("CONFIG_DIR") + System.getProperty("file.separator") + CONFIG_FILE_NAME); 207 } catch (Exception e) { 213 208 simManLogger.logp(Level.SEVERE, "SimulationManager", "Main", 214 209 "Error occured initializing application", e);
Note: See TracChangeset
for help on using the changeset viewer.
