Commit d017948d authored by Romain Bioteau's avatar Romain Bioteau
Browse files

feat(accessControl) fix error state page switch

parent dd802211
......@@ -37,6 +37,15 @@ public class BonitaGroovyEditor extends GroovyEditor {
menu.dispose();
}
/*
* (non-Javadoc)
* @see org.eclipse.jdt.internal.ui.javaeditor.JavaEditor#updateStatusLine()
*/
@Override
protected void updateStatusLine() {
}
/*
* (non-Javadoc)
* @see org.codehaus.groovy.eclipse.editor.GroovyEditor#createActions()
......
......@@ -130,7 +130,7 @@ public abstract class AbstractFormPage<T> extends FormPage {
public void recreateForm() {
if (scrolledForm != null) {
Stream.of(toolBarManager.getItems()).forEach(IContributionItem::update);
Stream.of(scrolledForm.getBody().getChildren()).forEach(Control::dispose);
disposePageContent();
createForm();
}
}
......@@ -166,7 +166,7 @@ public abstract class AbstractFormPage<T> extends FormPage {
public void loadErrorPage() {
if (scrolledForm != null) {
Stream.of(toolBarManager.getItems()).forEach(IContributionItem::update);
Stream.of(scrolledForm.getBody().getChildren()).forEach(Control::dispose);
disposePageContent();
final Composite composite = toolkit.createComposite(scrolledForm.getBody());
composite.setLayout(GridLayoutFactory.fillDefaults().create());
......@@ -185,9 +185,14 @@ public abstract class AbstractFormPage<T> extends FormPage {
final Label label = toolkit.createLabel(composite, Messages.parseError);
label.setLayoutData(GridDataFactory.fillDefaults().align(SWT.CENTER, SWT.CENTER).create());
label.setFont(BonitaStudioFontRegistry.getPreferenceTitleFont());
scrolledForm.getParent().layout(true, true);
}
}
protected void disposePageContent() {
Stream.of(scrolledForm.getBody().getChildren()).forEach(Control::dispose);
}
@Override
public AbstractEditor<T> getEditor() {
return (AbstractEditor<T>) super.getEditor();
......
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