Beispiel #1
0
        /// <summary>
        /// Handles the execution interruption by calling the handler of the current IState.
        /// </summary>
        /// <param name="reason">The interrupt reason.</param>
        protected virtual void HandleExecutionInterrupt(ExecutionInterruptReason reason)
        {
            var main = Platform.Gui.MainForm;

            // Invoke will most likely be required because
            // Debugger runs in a separate thread.
            if (main.InvokeRequired)
            {
                main.BeginInvoke(new Action <ExecutionInterruptReason>(HandleExecutionInterrupt), reason);
                return;
            }

            ExecutionInterruptReason = reason;
            if (CurrentIState != null)
            {
                CurrentIState.HandleExecutionInterrupt(reason);
            }
        }
Beispiel #2
0
 /// <summary>
 /// Steps out of the current sub-routine.
 /// </summary>
 /// <param name="back">A value indicating whether to take the step backwards.</param>
 public virtual void StepOut(bool back)
 {
     CurrentIState.StepOut(back);
 }
Beispiel #3
0
 /// <summary>
 /// Restarts the current program.
 /// </summary>
 public virtual void Restart()
 {
     CurrentIState.Restart();
 }
Beispiel #4
0
 /// <summary>
 /// Stops the program execution. It is not possible to continue.
 /// </summary>
 public virtual void Stop()
 {
     CurrentIState.Stop();
 }
Beispiel #5
0
 /// <summary>
 /// Pauses program execution.
 /// </summary>
 public virtual void Pause()
 {
     CurrentIState.Pause();
 }
Beispiel #6
0
 /// <summary>
 /// Starts on continues program execution.
 /// </summary>
 public virtual void Run()
 {
     CurrentIState.Run();
 }