List of usage examples for javax.swing JInternalFrame setName
public void setName(String name)
From source file:org.en.tealEye.guiMain.MainAppFrame.java
public void insertInternalFrame(ExtendedJPanelImpl name) { ExtendedJPanelImpl jPanelImpl;/* w ww.ja v a2s. c om*/ try { jPanelImpl = name; panelMap.put(name.getName(), name); JInternalFrame jInternalFrame = new JInternalFrame(); jInternalFrame.setSize(400, 300); jInternalFrame.setName(jPanelImpl.getName()); jInternalFrame.setTitle(jPanelImpl.getTitle()); jInternalFrame.getContentPane().add(new JScrollPane(jPanelImpl)); jInternalFrame.setIconifiable(true); jInternalFrame.setMaximizable(true); jInternalFrame.setResizable(true); jInternalFrame.setClosable(true); jInternalFrame.addInternalFrameListener(windowController); frameMap.put(jInternalFrame.getName(), jInternalFrame); desktop.add(jInternalFrame); desktop.getDesktopManager().activateFrame(jInternalFrame); desktop.getDesktopManager().maximizeFrame(jInternalFrame); jInternalFrame.moveToFront(); jInternalFrame.setSelected(true); jInternalFrame.setVisible(true); jInternalFrame.validate(); activeFrameMenu.addFrameButton(jPanelImpl.getName()); menuController.setActiveFrameName(jInternalFrame.getName()); } catch (Exception e) { log.error("cannot open panel " + name, e); } }