@Override public void removeDeviceView(DeviceView deviceView) { Component comp = tabs.get(deviceView); if (comp != null) { tabs.remove(deviceView); tabbedPane.remove(deviceView.asUIComponent()); } }
@Override public void actionPerformed(ActionEvent e) { // Remove the selected tab pane if it's not the Smack info pane if (tabbedPane.getSelectedIndex() < tabbedPane.getComponentCount() - 1) { int index = tabbedPane.getSelectedIndex(); // Notify to the debugger to stop debugging EnhancedDebugger debugger = debuggers.get(index); debugger.cancel(); // Remove the debugger from the root window tabbedPane.remove(debugger.tabbedPane); debuggers.remove(debugger); // Update the root window title frame.setTitle( "Smack Debug Window -- Total connections: " + (tabbedPane.getComponentCount() - 1)); } } });
public void closeOpenTab(int index) { RTextScrollPane co = (RTextScrollPane) house.getComponentAt(index); RSyntaxTextArea pane = (RSyntaxTextArea) co.getViewport().getView(); OpenFile open = null; for (OpenFile file : hmap) if (pane.equals(file.textArea)) open = file; if (open != null && hmap.contains(open)) hmap.remove(open); house.remove(co); if (open != null) open.close(); }
@Override public void actionPerformed(ActionEvent e) { ArrayList<EnhancedDebugger> debuggersToRemove = new ArrayList<>(); // Remove all the debuggers of which their connections are no longer valid for (int index = 0; index < tabbedPane.getComponentCount() - 1; index++) { EnhancedDebugger debugger = debuggers.get(index); if (!debugger.isConnectionActive()) { // Notify to the debugger to stop debugging debugger.cancel(); debuggersToRemove.add(debugger); } } for (EnhancedDebugger debugger : debuggersToRemove) { // Remove the debugger from the root window tabbedPane.remove(debugger.tabbedPane); debuggers.remove(debugger); } // Update the root window title frame.setTitle( "Smack Debug Window -- Total connections: " + (tabbedPane.getComponentCount() - 1)); } });
public void closeFile() { for (OpenFile co : hmap) { int pos = house.indexOfTab(co.name); if (pos >= 0) house.remove(pos); co.close(); } final State oldState = state; Model.this.state = null; if (oldState != null) { Closer.tryClose(oldState); } hmap.clear(); tree.setModel(new DefaultTreeModel(null)); metadataSystem = new MetadataSystem(typeLoader); file = null; treeExpansionState = null; open = false; mainWindow.onFileLoadEnded(file, open); }
tabbedPane.remove(i);
/** * Convenience method to remove a workspace tab. If the tab is discarded then its <code>dispose()</code> method must * be called. * * @param workspaceTab The tab to be removed. */ public void removeTab(WorkspaceTab workspaceTab) { tabbedPane.remove(workspaceTab); workspaceTabs.remove(workspaceTab); }
public void actionPerformed(ActionEvent arg0) { int index = tabs.getSelectedIndex(); tabs.remove(index); checkValidity(); }
/** * Removes a proifile fro the context. * @param profileId the ID of the profile to remove. */ public void remove(String profileId) { tabbedPane.remove(profiles.remove(profileId)); }
public void actionPerformed(ActionEvent e) { int tabIndex = sheetPane.getSelectedIndex(); if (tabIndex != -1) { if (JOptionPane.showConfirmDialog(sheetPane, "Are you sure that you want to delete the selected sheet", "Delete Sheet?", JOptionPane.OK_CANCEL_OPTION) == JOptionPane.OK_OPTION) { wb.removeSheetAt(tabIndex); sheetPane.remove(tabIndex); } } } }
public void actionPerformed(ActionEvent e) { int i = pane.indexOfTabComponent(ButtonTabComponent.this); if (i != -1) { pane.remove(i); } }
public void actionPerformed(ActionEvent e) { int i = pane.indexOfTabComponent(ButtonTabComponent.this); if (i != -1) { pane.remove(i); } }
@Override public void actionPerformed(ActionEvent e) { int tabIndex = sheetPane.getSelectedIndex(); if (tabIndex != -1) { if (JOptionPane.showConfirmDialog(sheetPane, "Are you sure that you want to delete the selected sheet", "Delete Sheet?", JOptionPane.OK_CANCEL_OPTION) == JOptionPane.OK_OPTION) { wb.removeSheetAt(tabIndex); sheetPane.remove(tabIndex); } } } }
/** * Removes specified component from the CytoPanel. * * @param component Component reference. */ public void remove(Component component) { // remove tab from JTabbedPane (component) tabbedPane.remove(component); // send out a notification notifyListeners(NOTIFICATION_COMPONENT_REMOVED); }
/** * Remove the detailed enactor progress report as a tree */ public void rmvProgressReport() { try { tabs.remove(tabs.indexOfTab("Process report")); } catch (Exception ex) { } }
@Override public void actionPerformed(final ActionEvent e) { final int tabIndex = tabbedPane.indexOfTabComponent(parent); if (tabIndex != TAB_NOT_FOUND) { tabbedPane.remove(tabIndex); } } }
public void actionPerformed(ActionEvent e) { int tabIndex = sheetPane.getSelectedIndex(); if (tabIndex != -1) { if (JOptionPane.showConfirmDialog(sheetPane, "Are you sure that you want to delete the selected sheet", "Delete Sheet?", JOptionPane.OK_CANCEL_OPTION) == JOptionPane.OK_OPTION) { wb.removeSheetAt(tabIndex); sheetPane.remove(tabIndex); } } } }
public void removeNavigator(JHelpNavigator nav) { debug("removeNavigator"); navs.removeElement(nav); tabbedPane.remove(nav); help.invalidate(); }
private void closeResultTab(ResultTab tab) { if (tab == null) { throw new IllegalArgumentException("Null ResultTab passed"); } s_log .debug("SQLPanel.closeResultTab(" + tab.getIdentifier().toString() + ")"); tab.closeTab(); _tabbedExecutionsPanel.remove(tab); }
public void actionPerformed(ActionEvent e) { ((DefaultListModel)sentmsgs.getModel()).removeAllElements(); ((DefaultListModel)receivedmsgs.getModel()).removeAllElements(); while(tabs.getComponentCount()>1) tabs.remove(1); } });