Commit 5298d521 authored by Alexander Weigl's avatar Alexander Weigl

working on KeyData.java

parent b439d2ef
Pipeline #12136 failed with stage
in 1 minute and 26 seconds
package edu.kit.formal.gui.controller; package edu.kit.formal.gui.controller;
import com.google.common.eventbus.Subscribe;
import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIcon; import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIcon;
import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIconView; import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIconView;
import de.uka.ilkd.key.proof.init.ProofInputException; import de.uka.ilkd.key.proof.init.ProofInputException;
...@@ -18,6 +19,7 @@ import javafx.beans.property.*; ...@@ -18,6 +19,7 @@ import javafx.beans.property.*;
import javafx.beans.value.ChangeListener; import javafx.beans.value.ChangeListener;
import javafx.beans.value.ObservableBooleanValue; import javafx.beans.value.ObservableBooleanValue;
import javafx.beans.value.ObservableValue; import javafx.beans.value.ObservableValue;
import javafx.collections.FXCollections;
import javafx.concurrent.Service; import javafx.concurrent.Service;
import javafx.concurrent.Task; import javafx.concurrent.Task;
import javafx.event.ActionEvent; import javafx.event.ActionEvent;
...@@ -51,12 +53,12 @@ import java.util.concurrent.Executors; ...@@ -51,12 +53,12 @@ import java.util.concurrent.Executors;
* @author Alexander Weigl * @author Alexander Weigl
*/ */
public class DebuggerMainWindowController implements Initializable { public class DebuggerMainWindowController implements Initializable {
public static final KeYProofFacade FACADE = new KeYProofFacade();
protected static final Logger LOGGER = LogManager.getLogger(DebuggerMainWindowController.class); protected static final Logger LOGGER = LogManager.getLogger(DebuggerMainWindowController.class);
public final ContractLoaderService contractLoaderService = new ContractLoaderService();
private final ProofTreeController proofTreeController = new ProofTreeController(); private final ProofTreeController proofTreeController = new ProofTreeController();
private final InspectionViewsController inspectionViewsController = new InspectionViewsController(); private final InspectionViewsController inspectionViewsController = new InspectionViewsController();
private final ExecutorService executorService = Executors.newFixedThreadPool(2); private final ExecutorService executorService = Executors.newFixedThreadPool(2);
public static final KeYProofFacade FACADE = new KeYProofFacade();
public final ContractLoaderService contractLoaderService = new ContractLoaderService();
/** /**
* Property: current loaded javaFile * Property: current loaded javaFile
*/ */
...@@ -70,8 +72,10 @@ public class DebuggerMainWindowController implements Initializable { ...@@ -70,8 +72,10 @@ public class DebuggerMainWindowController implements Initializable {
*/ */
private final ObjectProperty<Contract> chosenContract = new SimpleObjectProperty<>(this, "chosenContract"); private final ObjectProperty<Contract> chosenContract = new SimpleObjectProperty<>(this, "chosenContract");
private ScriptController scriptController; private ScriptController scriptController;
@FXML @FXML
private DebuggerStatusBar statusBar; private DebuggerStatusBar statusBar;
@FXML @FXML
private DockPane dockStation; private DockPane dockStation;
private JavaArea javaArea = new JavaArea(); private JavaArea javaArea = new JavaArea();
...@@ -107,6 +111,8 @@ public class DebuggerMainWindowController implements Initializable { ...@@ -107,6 +111,8 @@ public class DebuggerMainWindowController implements Initializable {
@Override @Override
public void initialize(URL location, ResourceBundle resources) { public void initialize(URL location, ResourceBundle resources) {
Events.register(this);
setDebugMode(false); setDebugMode(false);
scriptController = new ScriptController(dockStation); scriptController = new ScriptController(dockStation);
...@@ -115,12 +121,14 @@ public class DebuggerMainWindowController implements Initializable { ...@@ -115,12 +121,14 @@ public class DebuggerMainWindowController implements Initializable {
registerToolbarToStatusBar(); registerToolbarToStatusBar();
marriageProofTreeControllerWithActiveInspectionView(); marriageProofTreeControllerWithActiveInspectionView();
//statusBar.publishMessage("File: " + (newValue != null ? newValue.getAbsolutePath() : "n/a")); //statusBar.publishMessage("File: " + (newValue != null ? newValue.getAbsolutePath() : "n/a"));
marriageJavaCode();
//Debugging //Debugging
Utils.addDebugListener(javaCode); Utils.addDebugListener(javaCode);
Utils.addDebugListener(executeNotPossible, "executeNotPossible"); Utils.addDebugListener(executeNotPossible, "executeNotPossible");
scriptController.mainScriptProperty().bindBidirectional(statusBar.mainScriptIdentifierProperty());
} }
/** /**
...@@ -133,20 +141,29 @@ public class DebuggerMainWindowController implements Initializable { ...@@ -133,20 +141,29 @@ public class DebuggerMainWindowController implements Initializable {
proofTreeController.currentGoalsProperty().addListener((o, old, fresh) -> { proofTreeController.currentGoalsProperty().addListener((o, old, fresh) -> {
if (fresh != null) { if (fresh != null) {
imodel.setGoals(fresh); imodel.setGoals(fresh);
} else {
// no goals, set an empty list
imodel.setGoals(FXCollections.observableArrayList());
} }
}); });
proofTreeController.currentSelectedGoalProperty().addListener((observable, oldValue, newValue) -> { proofTreeController.currentSelectedGoalProperty().addListener((observable, oldValue, newValue) -> {
if (newValue != null) { imodel.setCurrentInterpreterGoal(newValue);
imodel.setCurrentInterpreterGoal(newValue); //also update the selected to be shown
} imodel.setSelectedGoalNodeToShow(newValue);
}); });
proofTreeController.currentHighlightNodeProperty().addListener((observable, oldValue, newValue) -> { proofTreeController.currentHighlightNodeProperty().addListener((observable, oldValue, newValue) -> {
scriptController.getDebugPositionHighlighter().highlight(newValue); scriptController.getDebugPositionHighlighter().highlight(newValue);
}); });
javaFileProperty().addListener((observable, oldValue, newValue) -> { Utils.addDebugListener(proofTreeController.currentGoalsProperty(), Utils::reprKeyDataList);
Utils.addDebugListener(proofTreeController.currentSelectedGoalProperty(), Utils::reprKeyData);
Utils.addDebugListener(proofTreeController.currentHighlightNodeProperty());
}
public void marriageJavaCode() {
/*javaFileProperty().addListener((observable, oldValue, newValue) -> {
showCodeDock(null); showCodeDock(null);
try { try {
String code = FileUtils.readFileToString(newValue, Charset.defaultCharset()); String code = FileUtils.readFileToString(newValue, Charset.defaultCharset());
...@@ -154,8 +171,14 @@ public class DebuggerMainWindowController implements Initializable { ...@@ -154,8 +171,14 @@ public class DebuggerMainWindowController implements Initializable {
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); e.printStackTrace();
} }
});*/
chosenContract.addListener(o -> {
javaCode.set(Utils.getJavaCode(chosenContract.get()));
showCodeDock(null);
}); });
javaCode.addListener(new ChangeListener<String>() { javaCode.addListener(new ChangeListener<String>() {
@Override @Override
public void changed(ObservableValue<? extends String> observable, String oldValue, String newValue) { public void changed(ObservableValue<? extends String> observable, String oldValue, String newValue) {
...@@ -166,11 +189,10 @@ public class DebuggerMainWindowController implements Initializable { ...@@ -166,11 +189,10 @@ public class DebuggerMainWindowController implements Initializable {
} }
} }
}); });
Utils.addDebugListener(proofTreeController.currentGoalsProperty());
Utils.addDebugListener(proofTreeController.currentSelectedGoalProperty());
Utils.addDebugListener(proofTreeController.currentHighlightNodeProperty());
} }
/** /**
* If the mouse moves other toolbar button, the help text should display in the status bar * If the mouse moves other toolbar button, the help text should display in the status bar
*/ */
......
package edu.kit.formal.gui.controller; package edu.kit.formal.gui.controller;
import com.google.common.eventbus.EventBus; import com.google.common.eventbus.EventBus;
import edu.kit.formal.gui.controls.ScriptArea;
import lombok.Data;
/** /**
* See http://codingjunkie.net/guava-eventbus/ for an introduction. * See http://codingjunkie.net/guava-eventbus/ for an introduction.
...@@ -10,11 +12,24 @@ import com.google.common.eventbus.EventBus; ...@@ -10,11 +12,24 @@ import com.google.common.eventbus.EventBus;
public class Events { public class Events {
public static final EventBus GLOBAL_EVENT_BUS = new EventBus(); public static final EventBus GLOBAL_EVENT_BUS = new EventBus();
public void register(Object object) { public static void register(Object object) {
GLOBAL_EVENT_BUS.register(object); GLOBAL_EVENT_BUS.register(object);
} }
public void unregister(Object object) { public static void unregister(Object object) {
GLOBAL_EVENT_BUS.unregister(object); GLOBAL_EVENT_BUS.unregister(object);
} }
public static void fire(Object focusScriptArea) {
GLOBAL_EVENT_BUS.post(focusScriptArea);
}
@Data
public static class FocusScriptArea {
private final ScriptArea scriptArea;
public FocusScriptArea(ScriptArea area) {
this.scriptArea = area;
}
}
} }
...@@ -89,7 +89,7 @@ public class PuppetMaster { ...@@ -89,7 +89,7 @@ public class PuppetMaster {
* Publish state is called after the interpreter or debugger thread terminated. The resulting goals are set in the root model * Publish state is called after the interpreter or debugger thread terminated. The resulting goals are set in the root model
*/ */
public void publishState() { public void publishState() {
System.out.println("PuppetMaster.publishState"); //("PuppetMaster.publishState");
//puppet is null if successful interpreter state and publish state //puppet is null if successful interpreter state and publish state
if (puppet != null) { if (puppet != null) {
......
...@@ -2,10 +2,9 @@ package edu.kit.formal.gui.controls; ...@@ -2,10 +2,9 @@ package edu.kit.formal.gui.controls;
import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIcon; import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIcon;
import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIconView; import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIconView;
import javafx.beans.property.ListProperty; import edu.kit.formal.gui.controller.Events;
import javafx.beans.property.SimpleListProperty; import edu.kit.formal.gui.model.MainScriptIdentifier;
import javafx.beans.property.SimpleObjectProperty; import javafx.beans.property.*;
import javafx.beans.property.SimpleStringProperty;
import javafx.beans.value.ObservableStringValue; import javafx.beans.value.ObservableStringValue;
import javafx.collections.FXCollections; import javafx.collections.FXCollections;
import javafx.collections.ObservableList; import javafx.collections.ObservableList;
...@@ -33,22 +32,23 @@ import java.util.LinkedList; ...@@ -33,22 +32,23 @@ import java.util.LinkedList;
*/ */
public class DebuggerStatusBar extends StatusBar { public class DebuggerStatusBar extends StatusBar {
private static final Logger LOGGER = LogManager.getLogger(DebuggerStatusBar.class); private static final Logger LOGGER = LogManager.getLogger(DebuggerStatusBar.class);
private final Appender loggerHandler = createAppender();
private final ContextMenu contextMenu = createContextMenu();
private ObjectProperty<MainScriptIdentifier> mainScriptIdentifier = new SimpleObjectProperty<>();
private Label lblCurrentNodes = new Label("#nodes: %s"); private Label lblCurrentNodes = new Label("#nodes: %s");
private Label lblMainscript = new Label();
private ProgressIndicator progressIndicator = new ProgressIndicator(); private ProgressIndicator progressIndicator = new ProgressIndicator();
private LogCatchHandlerFX logCatchHandler = new LogCatchHandlerFX(); private LogCatchHandlerFX logCatchHandler = new LogCatchHandlerFX();
private final Dialog<Void> loggerDialog = createDialog();
private EventHandler<MouseEvent> toolTipHandler = event -> { private EventHandler<MouseEvent> toolTipHandler = event -> {
publishMessage(((Control) event.getTarget()).getTooltip().getText()); publishMessage(((Control) event.getTarget()).getTooltip().getText());
}; };
private final ContextMenu contextMenu = createContextMenu();
private final Dialog<Void> loggerDialog = createDialog();
public DebuggerStatusBar() { public DebuggerStatusBar() {
listenOnField("psdbg"); listenOnField("psdbg");
getRightItems().addAll( getRightItems().addAll(
lblMainscript,
lblCurrentNodes, lblCurrentNodes,
progressIndicator progressIndicator
); );
...@@ -60,9 +60,32 @@ public class DebuggerStatusBar extends StatusBar { ...@@ -60,9 +60,32 @@ public class DebuggerStatusBar extends StatusBar {
}); });
} mainScriptIdentifier.addListener((ov, o, n) -> {
if (n != null) {
lblMainscript.setText("Main Script: " +
n.getScriptArea().getFilePath().getName() +
(n.getScriptName() != null
? '\\' + n.getScriptName()
: " @ " + n.getLineNumber()));
lblMainscript.setStyle("-fx-background-color: greenyellow;-fx-padding: 5pt;");
} else {
lblMainscript.setStyle("-fx-background-color: orangered;-fx-padding: 5pt;");
lblMainscript.setText("No main script selected");
}
});
private final Appender loggerHandler = createAppender(); lblMainscript.setStyle("-fx-background-color: orangered;-fx-padding: 5pt;");
lblMainscript.setText("No main script selected");
lblMainscript.setOnMouseClicked(event -> {
if (event.getClickCount() == 2) {
event.consume();
ScriptArea area = mainScriptIdentifier.get().getScriptArea();
Events.fire(new Events.FocusScriptArea(area));
}
});
}
private Appender createAppender() { private Appender createAppender() {
PatternLayout layout = PatternLayout.createDefaultLayout(); PatternLayout layout = PatternLayout.createDefaultLayout();
...@@ -117,6 +140,18 @@ public class DebuggerStatusBar extends StatusBar { ...@@ -117,6 +140,18 @@ public class DebuggerStatusBar extends StatusBar {
return cm; return cm;
} }
public MainScriptIdentifier getMainScriptIdentifier() {
return mainScriptIdentifier.get();
}
public void setMainScriptIdentifier(MainScriptIdentifier mainScriptIdentifier) {
this.mainScriptIdentifier.set(mainScriptIdentifier);
}
public ObjectProperty<MainScriptIdentifier> mainScriptIdentifierProperty() {
return mainScriptIdentifier;
}
private void showLog(ActionEvent actionEvent) { private void showLog(ActionEvent actionEvent) {
loggerDialog.show(); loggerDialog.show();
} }
...@@ -192,14 +227,14 @@ public class DebuggerStatusBar extends StatusBar { ...@@ -192,14 +227,14 @@ public class DebuggerStatusBar extends StatusBar {
return records.get(); return records.get();
} }
public ListProperty<LogEvent> recordsProperty() {
return records;
}
public void setRecords(ObservableList<LogEvent> records) { public void setRecords(ObservableList<LogEvent> records) {
this.records.set(records); this.records.set(records);
} }
public ListProperty<LogEvent> recordsProperty() {
return records;
}
public int getMaxRecords() { public int getMaxRecords() {
return maxRecords; return maxRecords;
} }
......
...@@ -35,15 +35,19 @@ public class InspectionView extends BorderPane { ...@@ -35,15 +35,19 @@ public class InspectionView extends BorderPane {
public InspectionView() { public InspectionView() {
Utils.createWithFXML(this); Utils.createWithFXML(this);
model.get().selectedGoalNodeToShowProperty().bind( model.get().selectedGoalNodeToShowProperty().addListener((o, a, b) -> {
goalView.getSelectionModel().selectedItemProperty() goalView.getSelectionModel().select(b);
); });
goalView.getSelectionModel().selectedItemProperty().addListener((o, a, b) -> {
model.get().setSelectedGoalNodeToShow(b);
});
model.get().selectedGoalNodeToShowProperty().addListener( model.get().selectedGoalNodeToShowProperty().addListener(
(observable, oldValue, newValue) -> { (observable, oldValue, newValue) -> {
goalView.getSelectionModel().select(newValue); goalView.getSelectionModel().select(newValue);
if (newValue != null && newValue.getData() != null) { if (newValue != null && newValue.getData() != null) {
getSequentView().setNode(newValue.getData().getGoal()); getSequentView().setNode(newValue.getData().getNode());
getSequentView().setGoal(newValue.getData().getGoal());
// TODO weigl: get marked lines of the program, and set it // TODO weigl: get marked lines of the program, and set it
model.get().highlightedJavaLinesProperty().get() model.get().highlightedJavaLinesProperty().get()
.clear(); .clear();
...@@ -83,6 +87,14 @@ public class InspectionView extends BorderPane { ...@@ -83,6 +87,14 @@ public class InspectionView extends BorderPane {
goalOptionsMenu.show(n, actionEvent.getScreenX(), actionEvent.getScreenY()); goalOptionsMenu.show(n, actionEvent.getScreenX(), actionEvent.getScreenY());
} }
public InspectionModel getModel() {
return model.get();
}
public ReadOnlyObjectProperty<InspectionModel> modelProperty() {
return model;
}
/** /**
* Cells for GoalView * Cells for GoalView
*/ */
...@@ -106,12 +118,4 @@ public class InspectionView extends BorderPane { ...@@ -106,12 +118,4 @@ public class InspectionView extends BorderPane {
setText(text); setText(text);
} }
} }
public InspectionModel getModel() {
return model.get();
}
public ReadOnlyObjectProperty<InspectionModel> modelProperty() {
return model;
}
} }
package edu.kit.formal.gui.controls; package edu.kit.formal.gui.controls;
import com.google.common.eventbus.Subscribe;
import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIcon; import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIcon;
import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIconView; import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIconView;
import edu.kit.formal.gui.controller.Events;
import edu.kit.formal.gui.model.Breakpoint; import edu.kit.formal.gui.model.Breakpoint;
import edu.kit.formal.gui.model.MainScriptIdentifier; import edu.kit.formal.gui.model.MainScriptIdentifier;
import edu.kit.formal.proofscriptparser.Facade; import edu.kit.formal.proofscriptparser.Facade;
...@@ -21,6 +23,7 @@ import org.apache.logging.log4j.Logger; ...@@ -21,6 +23,7 @@ import org.apache.logging.log4j.Logger;
import org.dockfx.DockNode; import org.dockfx.DockNode;
import org.dockfx.DockPane; import org.dockfx.DockPane;
import org.dockfx.DockPos; import org.dockfx.DockPos;
import sun.reflect.generics.reflectiveObjects.NotImplementedException;
import java.io.File; import java.io.File;
import java.io.IOException; import java.io.IOException;
...@@ -44,6 +47,13 @@ public class ScriptController { ...@@ -44,6 +47,13 @@ public class ScriptController {
public ScriptController(DockPane parent) { public ScriptController(DockPane parent) {
this.parent = parent; this.parent = parent;
Events.register(this);
}
@Subscribe public void handle(Events.FocusScriptArea fsa) {
logger.debug("FocusScriptArea handled!");
openScripts.get(fsa.getScriptArea()).focus();
fsa.getScriptArea().requestFocus();
} }
public ObservableMap<ScriptArea, DockNode> getOpenScripts() { public ObservableMap<ScriptArea, DockNode> getOpenScripts() {
...@@ -111,7 +121,7 @@ public class ScriptController { ...@@ -111,7 +121,7 @@ public class ScriptController {
this.lastScriptArea = area; this.lastScriptArea = area;
area.focusedProperty().addListener((observable, oldValue, newValue) -> { area.focusedProperty().addListener((observable, oldValue, newValue) -> {
System.out.println("area = [" + area + "]"); logger.debug("area = [" + area + "]");
if (newValue) if (newValue)
lastScriptArea = area; lastScriptArea = area;
}); });
...@@ -168,7 +178,19 @@ public class ScriptController { ...@@ -168,7 +178,19 @@ public class ScriptController {
} }
public void saveCurrentScript() { public void saveCurrentScript() {
//TODO throw new NotImplementedException();
}
public MainScriptIdentifier getMainScript() {
return mainScript.get();
}
public ObjectProperty<MainScriptIdentifier> mainScriptProperty() {
return mainScript;
}
public void setMainScript(MainScriptIdentifier mainScript) {
this.mainScript.set(mainScript);
} }
private ScriptArea findEditor(ASTNode node) { private ScriptArea findEditor(ASTNode node) {
...@@ -186,13 +208,20 @@ public class ScriptController { ...@@ -186,13 +208,20 @@ public class ScriptController {
} }
public void remove() { public void remove() {
if (lastScriptArea != null) logger.debug("remove highlight");
if (lastScriptArea != null) {
logger.debug("previous highlight on {} for {}", lastScriptArea, lastRegion);
lastScriptArea.getMarkedRegions().remove(lastRegion); lastScriptArea.getMarkedRegions().remove(lastRegion);
}
} }
public void highlight(ASTNode node) { public void highlight(ASTNode node) {
logger.debug("Highlight requested for {}", node);
remove(); remove();
ScriptArea.RegionStyle r = asRegion(node); ScriptArea.RegionStyle r = asRegion(node);
logger.debug("Region for highlighting: {}", r);
ScriptArea area = findEditor(node); ScriptArea area = findEditor(node);
area.getMarkedRegions().add(r); area.getMarkedRegions().add(r);
......
...@@ -5,10 +5,12 @@ import de.uka.ilkd.key.logic.NamespaceSet; ...@@ -5,10 +5,12 @@ import de.uka.ilkd.key.logic.NamespaceSet;
import de.uka.ilkd.key.logic.Sequent; import de.uka.ilkd.key.logic.Sequent;
import de.uka.ilkd.key.pp.*; import de.uka.ilkd.key.pp.*;
import de.uka.ilkd.key.proof.Goal; import de.uka.ilkd.key.proof.Goal;
import de.uka.ilkd.key.proof.Node;
import de.uka.ilkd.key.settings.ProofIndependentSettings; import de.uka.ilkd.key.settings.ProofIndependentSettings;
import edu.kit.formal.interpreter.KeYProofFacade; import edu.kit.formal.interpreter.KeYProofFacade;
import javafx.beans.Observable; import javafx.beans.Observable;
import javafx.beans.property.SimpleObjectProperty; import javafx.beans.property.SimpleObjectProperty;
import javafx.beans.value.ObservableBooleanValue;
import javafx.scene.input.MouseButton; import javafx.scene.input.MouseButton;
import javafx.scene.input.MouseEvent; import javafx.scene.input.MouseEvent;
import javafx.scene.layout.*; import javafx.scene.layout.*;
...@@ -28,7 +30,9 @@ public class SequentView extends CodeArea { ...@@ -28,7 +30,9 @@ public class SequentView extends CodeArea {
private LogicPrinter lp; private LogicPrinter lp;
private IdentitySequentPrintFilter filter; private IdentitySequentPrintFilter filter;
private LogicPrinter.PosTableStringBackend backend; private LogicPrinter.PosTableStringBackend backend;
private SimpleObjectProperty<de.uka.ilkd.key.proof.Goal> node = new SimpleObjectProperty<>(); private SimpleObjectProperty<de.uka.ilkd.key.proof.Goal> goal = new SimpleObjectProperty<>();
private SimpleObjectProperty<de.uka.ilkd.key.proof.Node> node = new SimpleObjectProperty<>();
private ObservableBooleanValue rulesAvailable = goal.isNotNull();
private KeYProofFacade keYProofFacade; private KeYProofFacade keYProofFacade;
private TacletContextMenu menu; private TacletContextMenu menu;
...@@ -63,13 +67,13 @@ public class SequentView extends CodeArea { ...@@ -63,13 +67,13 @@ public class SequentView extends CodeArea {
if (backend == null) { if (backend == null) {
return; return;
} }
if (e.getButton() == MouseButton.SECONDARY) { if (e.getButton() == MouseButton.SECONDARY && rulesAvailable.get()) {
CharacterHit hit = hit(e.getX(), e.getY()); CharacterHit hit = hit(e.getX(), e.getY());
int insertionPoint = hit.getInsertionIndex(); int insertionPoint = hit.getInsertionIndex();
PosInSequent pis = backend.getInitialPositionTable().getPosInSequent(insertionPoint, filter); PosInSequent pis = backend.getInitialPositionTable().getPosInSequent(insertionPoint, filter);
if (pis == null) return; if (pis == null) return;
menu = new TacletContextMenu(keYProofFacade, pis, node.get()); menu = new TacletContextMenu(keYProofFacade, pis, goal.get());
menu.setAutoFix(true); menu.setAutoFix(true);
menu.setAutoHide(true); menu.setAutoHide(true);
menu.show(this, e.getScreenX(), e.getScreenY()); menu.show(this, e.getScreenX(), e.getScreenY());
...@@ -125,24 +129,36 @@ public class SequentView extends CodeArea { ...@@ -125,24 +129,36 @@ public class SequentView extends CodeArea {