+ ToolBar toolBar = new ToolBar(parent, SWT.BORDER);
+ toolBar.setLayoutData(d);
+
+ ToolItem file = new ToolItem(toolBar, SWT.DROP_DOWN);
+
+ // TODO
+ DropDownEntry newEntry = new DropDownEntry("New", e -> Editor.openNewEditor());
+ DropDownEntry loadEntry = new DropDownEntry("Load", e ->
+ {
+ try
+ {
+ SaveLoadManager.openLoadDialog();
+ }
+ catch (IOException e1)
+ {
+ editor.dialogManager.openWarningDialog("Failed to load Component!", e1.getMessage());
+ }
+ });
+ DropDownEntry saveEntry = new DropDownEntry("Save", e -> editor.save());
+ DropDownEntry saveAsEntry = new DropDownEntry("Save as...", e -> editor.saveAs());
+
+ DropDownEntry[] entries = new DropDownEntry[] { newEntry, loadEntry, saveEntry, saveAsEntry };
+
+ setupDrowpDownMenu(file, entries);
+
+ file.setText("File");
+ return toolBar;
+ }
+
+ private ToolBar setupBottomToolBar(Composite parent)
+ {
+ GridData d = new GridData();
+ d.grabExcessHorizontalSpace = true;
+ d.horizontalAlignment = SWT.FILL;
+
+ ToolBar toolBar = new ToolBar(parent, SWT.BORDER);