Changeset 654 in tmcsimulator for trunk/src/tmcsim/cadsimulator/CADServer.java


Ignore:
Timestamp:
09/09/2022 04:11:08 PM (4 years ago)
Author:
jdalbey
Message:

TrafficModelManager?.java changed timer from Swing timer to java.util.timer to avoid any potential thread locking issues.
CADServer.java moved call to traffic mgr run() until after setVisible ... fix obscure bug on laptop NetBeans.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/tmcsim/cadsimulator/CADServer.java

    r455 r654  
    291291                    theCoordinator); 
    292292            theTrafficMgr.addObserver(theViewer); 
    293             theTrafficMgr.run(); 
    294  
     293     
    295294            theMediaMgr = new MediaManager( 
    296295                    cadServerProperties.getProperty( 
     
    346345 
    347346        theViewer.setVisible(true); 
     347        // I think the traffic mgr has to run AFTER viewer is set visible, because 
     348        // inside run() it loads traffic events and wants to notify the view 
     349        // to update itself ... so the view must be visible first? 
     350        // When this stmt was prior to setVisible, we hung on setVisible. 
     351        theTrafficMgr.run(); 
    348352 
    349353    } 
Note: See TracChangeset for help on using the changeset viewer.