1 package debugger.gui.actions.debugging;
2
3 import debugger.resources.ResourcesFactory;
4 import debugger.JapeDebugger;
5
6 import javax.swing.*;
7 import java.awt.event.ActionEvent;
8
9
15 public class ExecuteRHSAction extends AbstractAction {
16 private static ExecuteRHSAction ourInstance;
17
18 public synchronized static ExecuteRHSAction getInstance() {
19 if (ourInstance == null) {
20 ourInstance = new ExecuteRHSAction();
21 }
22 return ourInstance;
23 }
24
25
28 private ExecuteRHSAction() {
29 super();
30 putValue(Action.SHORT_DESCRIPTION, new String("Execute RHS"));
31 putValue(Action.SMALL_ICON, new ImageIcon(JapeDebugger.class.getResource("gui/icons/exeRHS.png")));
32 setEnabled(false);
33 }
34
35 public void actionPerformed(ActionEvent aEvt) {
36 setEnabled(false);
37 ResourcesFactory.getPhaseController().setStopAfterRHSExec(true);
38 ResourcesFactory.getPhaseController().continueSPT();
39 }
40 }
41
42