diff --git a/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/plugin.xml b/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/plugin.xml
index 4b953af..81c84cd 100644
--- a/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/plugin.xml
+++ b/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/plugin.xml
@@ -70,11 +70,6 @@
-
-
-
1) {
+ var parent = new MenuItem(menu, SWT.CASCADE, 0);
+ parent.setText("Typ einsetzen");
+ var subMenu = new Menu(parent);
+ parent.setMenu(subMenu);
+ for (var marker : editorContext.currentMarkers) {
+ var item = new MenuItem(subMenu, SWT.PUSH);
+ item.setText(marker.getInsertPoint().getInsertString());
+ item.addSelectionListener(new SelectionHandler(marker));
+ }
+ } else {
+ var marker = editorContext.currentMarkers.get(0);
+ var item = new MenuItem(menu, SWT.PUSH, 0);
+ item.setText(marker.getInsertPoint().getInsertString() + " einsetzen");
+ item.addSelectionListener(new SelectionHandler(marker));
}
+
}
@Override
diff --git a/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/src/typinferenzplugin/marker/QuickFix.java b/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/src/typinferenzplugin/marker/QuickFix.java
deleted file mode 100644
index 0320c95..0000000
--- a/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/src/typinferenzplugin/marker/QuickFix.java
+++ /dev/null
@@ -1,19 +0,0 @@
-package typinferenzplugin.marker;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.ui.IMarkerResolution;
-
-public class QuickFix implements IMarkerResolution {
- String label;
- QuickFix(String label) {
- this.label = label;
- }
- public String getLabel() {
- return label;
- }
- public void run(IMarker marker) {
- MessageDialog.openInformation(null, "QuickFix Demo",
- "This quick-fix is not yet implemented");
- }
- }
\ No newline at end of file
diff --git a/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/src/typinferenzplugin/marker/QuickFixer.java b/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/src/typinferenzplugin/marker/QuickFixer.java
deleted file mode 100644
index 4a228da..0000000
--- a/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/src/typinferenzplugin/marker/QuickFixer.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package typinferenzplugin.marker;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.ui.IMarkerResolution;
-import org.eclipse.ui.IMarkerResolutionGenerator;
-
-public class QuickFixer implements IMarkerResolutionGenerator {
-
- public IMarkerResolution[] getResolutions(IMarker mk) {
- return new IMarkerResolution[] {
- new QuickFix("Fix #1 for ")
- };
- }
-
-
-}