示例#1
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="e"></param>
 protected virtual void simulationStateChanged(SimulationStateUpdateEventArgs e)
 {
     if (SimulationStateChanged != null)
     {
         SimulationStateChanged(this, e);
     }
 }
示例#2
0
        /// <summary>
        /// Trigger function to start the Simulation State Chnge Event
        /// </summary>
        /// <param name="currentState"></param>
        private void triggerSimulationStateChangedEvent(Simulation_State currentState)
        {
            state = currentState;
            SimulationStateUpdateEventArgs myArgument = new SimulationStateUpdateEventArgs();

            myArgument.simulationState = currentState;
            simulationStateChanged(myArgument);
        }
示例#3
0
 /// <summary>
 /// Event Handler from the Simulation Interface
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void simStateChenged(object sender, SimulationStateUpdateEventArgs e)
 {
     this.Dispatcher.Invoke(DispatcherPriority.Normal, new System.Windows.Threading.DispatcherOperationCallback(delegate
     {
         // Update the UI via a function
         updateSimulationStatusUi(e.simulationState);
         return(null);
     }), null);
 }