Commit c11ab2f6 authored by Johannes Roith's avatar Johannes Roith

Update conflicts view correctly.

parent d1ca42bb
......@@ -6,6 +6,8 @@ import java.util.List;
import org.eclipse.swt.SWT;
import org.eclipse.swt.custom.ScrolledComposite;
import org.eclipse.swt.events.MouseEvent;
import org.eclipse.swt.events.MouseWheelListener;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.graphics.Color;
......@@ -400,32 +402,33 @@ public class CupConflictsView extends FailableView implements ICupEditorPageVisi
updateConflicts(crm);
showMain();
} else {
showError("Parse Tables do not match the current document.");
showParseTablesError();
}
} else {
showError("Parse Tables currently not available.");
showParseTablesError();
matchPanelNumber(0);
}
}
private void showParseTablesError() {
showError("Parse Tables currently not available.");
}
@Override
public void willBecomeVisible() {
this.isVisible = true;
if (!Controller.getInstance(editor).requestJobRun()) {
// the requested job won't run.
System.out.println("NO RERUN!!!"); // TODO
Model model = Model.getInstanceForDocument(editor.getDocument());
handleModelUpdate(model);
} else {
showError("Requested job run ...");
}
}
@Override
public void modelChanged(Model model) {
// TODO: only update if visible?
handleModelUpdate(model);
}
......@@ -444,12 +447,8 @@ public class CupConflictsView extends FailableView implements ICupEditorPageVisi
@Override
public void jobStatusChanged(JobStatus status) {
// TODO: if the job failed, we can show an appropriate error here.
// and update the current status message.
if (status.getAffectedJob() == JobsToDo.buildTable && status.hasFailed())
showParseTablesError();
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment