ContentWindow window = (ContentWindow) SwingUtilities.windowForComponent(content.getComponent());
window.removeDockable(content);
if (window.getDockableCount() <= 0) {
window.setVisible(false);
window.dispose();
}
contentValueAdjusting = true;
try {
int index = 0;