private void showHiddenTabPopup() {
		JPopupMenu menu = new JPopupMenu();
		if (getMousePosition() == null) {
			// Startup
			return;
		}
		Collections.sort(this.hiddenTabs, NAME_COMPARATOR);
		
		for (Component c : this.hiddenTabs) {
			if (c instanceof AbstractPanel) {
				final AbstractPanel ap = (AbstractPanel)c;
				JMenuItem mi = new JMenuItem(ap.getName());
				mi.setIcon(ap.getIcon());
				mi.addActionListener(new ActionListener(){
					@Override
					public void actionPerformed(ActionEvent e) {
						setVisible(ap, true);
						ap.setTabFocus();
					}});
				menu.add(mi);
			}
		}
		menu.show(this, this.getMousePosition().x, this.getMousePosition().y);
	}
private void showHiddenTabPopup ( ) { JPopupMenu menu = new JPopupMenu ( ) ; if ( getMousePosition ( ) == null ) { return ; } Collections . sort ( this . hiddenTabs , NAME_COMPARATOR ) ; for ( Component c : this . hiddenTabs ) { if ( c instanceof AbstractPanel ) { final AbstractPanel ap = ( AbstractPanel ) c ; JMenuItem mi = new JMenuItem ( ap . getName ( ) ) ; mi . setIcon ( ap . getIcon ( ) ) ; mi . addActionListener ( new ActionListener ( ) { @ Override public void actionPerformed ( ActionEvent e ) { setVisible ( ap , true ) ; ap . setTabFocus ( ) ; } } ) ; menu . add ( mi ) ; } } menu . show ( this , this . getMousePosition ( ) . x , this . getMousePosition ( ) . y ) ; }
Show a popup containing a list of all of the hidden tabs - selecting one will reveal that tab