Search in sources :

Example 1 with PluginPathPart

use of bndtools.editor.workspace.PluginPathPart in project bndtools by bndtools.

the class WorkspacePage method createFormContent.

@Override
protected void createFormContent(IManagedForm managedForm) {
    managedForm.setInput(model);
    FormToolkit tk = managedForm.getToolkit();
    ScrolledForm form = managedForm.getForm();
    form.setText("Workspace Config");
    tk.decorateFormHeading(form.getForm());
    form.getForm().addMessageHyperlinkListener(new MessageHyperlinkAdapter(getEditor()));
    // Create controls
    Composite body = form.getBody();
    WorkspaceMainPart linksPart = new WorkspaceMainPart(mainBuildFile, body, tk, Section.TITLE_BAR | Section.EXPANDED | Section.DESCRIPTION);
    managedForm.addPart(linksPart);
    PluginPathPart pluginPathPart = new PluginPathPart(body, tk, Section.TITLE_BAR | Section.EXPANDED | Section.DESCRIPTION | Section.TWISTIE);
    managedForm.addPart(pluginPathPart);
    pluginsPart = new PluginsPart(body, tk, Section.TITLE_BAR | Section.EXPANDED | Section.DESCRIPTION | Section.TWISTIE);
    managedForm.addPart(pluginsPart);
    // Layout
    GridLayout layout = new GridLayout(1, false);
    body.setLayout(layout);
    linksPart.getSection().setLayoutData(PageLayoutUtils.createCollapsed());
    pluginPathPart.getSection().setLayoutData(PageLayoutUtils.createExpanded());
    pluginPathPart.getSection().addExpansionListener(new ResizeExpansionAdapter(pluginPathPart.getSection()));
    pluginsPart.getSection().setLayoutData(PageLayoutUtils.createExpanded());
    pluginsPart.getSection().addExpansionListener(new ResizeExpansionAdapter(pluginsPart.getSection()));
}
Also used : PluginsPart(bndtools.editor.workspace.PluginsPart) GridLayout(org.eclipse.swt.layout.GridLayout) MessageHyperlinkAdapter(bndtools.utils.MessageHyperlinkAdapter) FormToolkit(org.eclipse.ui.forms.widgets.FormToolkit) Composite(org.eclipse.swt.widgets.Composite) ScrolledForm(org.eclipse.ui.forms.widgets.ScrolledForm) PluginPathPart(bndtools.editor.workspace.PluginPathPart) WorkspaceMainPart(bndtools.editor.workspace.WorkspaceMainPart)

Aggregations

PluginPathPart (bndtools.editor.workspace.PluginPathPart)1 PluginsPart (bndtools.editor.workspace.PluginsPart)1 WorkspaceMainPart (bndtools.editor.workspace.WorkspaceMainPart)1 MessageHyperlinkAdapter (bndtools.utils.MessageHyperlinkAdapter)1 GridLayout (org.eclipse.swt.layout.GridLayout)1 Composite (org.eclipse.swt.widgets.Composite)1 FormToolkit (org.eclipse.ui.forms.widgets.FormToolkit)1 ScrolledForm (org.eclipse.ui.forms.widgets.ScrolledForm)1