content.setVisible(true);
window.getContentPane().add(content, "1,1,FULL,FULL");
if (lastBounds == null) {
FloatingTypeDescriptor typeDescriptor = (FloatingTypeDescriptor) descriptor.getTypeDescriptor(ToolWindowType.FLOATING);
// Set Size
if (typeDescriptor.getSize() == null) {
Component parentComponent = descriptor.getManager().getParentComponent();
window.setSize(parentComponent.getWidth() / 2, (int) (parentComponent.getHeight() / 1.5));
} else {
window.setSize(typeDescriptor.getSize());
}
// Set Location
if (typeDescriptor.getLocation() == null) {
SwingUtil.centrePositionOnScreen(window);
} else
window.setLocation(typeDescriptor.getLocation());
} else {
window.setBounds(lastBounds);
lastBounds = null;
}
if (descriptor.getTypeDescriptor(ToolWindowType.FLOATING).isAnimating()) {
floatingAnimation.show();
} else {
FloatingTypeDescriptor typeDescriptor = (FloatingTypeDescriptor) descriptor.getTypeDescriptor(ToolWindowType.FLOATING);
window.setModal(typeDescriptor.isModal());
window.setVisible(true);
window.getContentPane().setVisible(true);
SwingUtil.repaint(window);
if (!window.isFocused() && toolWindow.isActive())