-
- Composite buttons = new Composite(editorArea, SWT.NONE);
- buttons.setLayout(new RowLayout(SWT.HORIZONTAL));
- Button delete = new Button(buttons, SWT.PUSH);
- delete.setText("Delete");
- editorArea.setTopRight(buttons);
-
- CTabItem defaultTab = new CTabItem(editorArea, SWT.NONE);
- defaultTab.setText("Home");
- defaultBody = new Composite(editorArea, SWT.NONE);
+ editorArea.setLayout(new GridLayout());
+
+ editorTabFolder = new CTabFolder(editorArea, SWT.NONE);
+ editorTabFolder.setLayoutData(CmsUiUtils.fillAll());
+
+ // TODO make it dynamic
+ Composite buttons = new Composite(editorTabFolder, SWT.NONE);
+ buttons.setLayout(CmsUiUtils.noSpaceGridLayout());
+ ToolBar toolBar = new ToolBar(buttons, SWT.NONE);
+ toolBar.setLayoutData(new GridData(SWT.END, SWT.TOP, false, false));
+ ToolItem deleteItem = new ToolItem(toolBar, SWT.PUSH);
+ deleteItem.setImage(SuiteIcon.delete.getSmallIcon(theme));
+ deleteItem.setEnabled(false);
+ editorTabFolder.setTopRight(buttons);
+
+ CTabItem defaultTab = new CTabItem(editorTabFolder, SWT.NONE);
+ // defaultTab.setText("Home");
+ defaultTab.setImage(dashboard.getSmallIcon(theme));
+ defaultBody = new Composite(editorTabFolder, SWT.NONE);