/** * Override of the <code>Workspace</code> initialise method. */ public void initialise() { JPanel tabHolder = new JPanel(new BorderLayout()); workspaceTabs = new HashSet<WorkspaceTab>(); // Create the tabs. tabbedPane = new JTabbedPane(); tabHolder.add(tabbedPane); setContent(tabbedPane); // Here we either need to load the default tabs, or // restore a set of tabs final List<String> visibleTabs = new TabbedWorkspaceStateManager().getTabs(); // If no tabs are set as visible (ie we have yet to customise, show all by default for (WorkspaceTabPlugin plugin : getOrderedPlugins()) { if (visibleTabs.isEmpty() || visibleTabs.contains(plugin.getId())) { addTabForPlugin(plugin); } } }
/** * Override of the <code>Workspace</code> initialise method. */ public void initialise() { JPanel tabHolder = new JPanel(new BorderLayout()); workspaceTabs = new HashSet<WorkspaceTab>(); // Create the tabs. tabbedPane = new JTabbedPane(); tabHolder.add(tabbedPane); setContent(tabbedPane); // Here we either need to load the default tabs, or // restore a set of tabs final List<String> visibleTabs = new TabbedWorkspaceStateManager().getTabs(); // If no tabs are set as visible (ie we have yet to customise, show all by default for (WorkspaceTabPlugin plugin : getOrderedPlugins()) { if (visibleTabs.isEmpty() || visibleTabs.contains(plugin.getId())) { addTabForPlugin(plugin); } } }
public void rebuildChildMenuItems(JMenu thisMenuItem) { if (!(getWorkspace() instanceof TabbedWorkspace)) { // Don't bother to show a tabs menu for non // tabbed workspaces. return; } thisMenuItem.removeAll(); for (final WorkspaceTabPlugin plugin : ((TabbedWorkspace) getWorkspace()).getOrderedPlugins()) { addMenuItem(thisMenuItem, plugin); } }
public void rebuildChildMenuItems(JMenu thisMenuItem) { if (!(getWorkspace() instanceof TabbedWorkspace)) { // Don't bother to show a tabs menu for non // tabbed workspaces. return; } thisMenuItem.removeAll(); for (final WorkspaceTabPlugin plugin : ((TabbedWorkspace) getWorkspace()).getOrderedPlugins()) { addMenuItem(thisMenuItem, plugin); } }
public void rebuildChildMenuItems(JMenu thisMenuItem) { if (!(getWorkspace() instanceof TabbedWorkspace)) { // Don't bother to show a tabs menu for non // tabbed workspaces. return; } thisMenuItem.removeAll(); for (final WorkspaceTabPlugin plugin : ((TabbedWorkspace) getWorkspace()).getOrderedPlugins()) { addMenuItem(thisMenuItem, plugin); } }
public void initialise() { // Here we either need to load the default tabs, or // restore a set of tabs final List<String> visibleTabs = new TabbedWorkspaceStateManager().getTabs(); // If no tabs are set as visible (i.e. we have yet to customise) show all by default for (WorkspaceTabPlugin plugin : getOrderedPlugins()) { if(visibleTabs.isEmpty()) { if(plugin.isProtegeDefaultTab()) { addTabForPlugin(plugin); } } else if (visibleTabs.contains(plugin.getId())) { addTabForPlugin(plugin); } } }