CommanderPanel () { final CommanderPanel panel = new CommanderPluginPanel(project, true, false); panel.getList().addKeyListener(new PsiCopyPasteManager.EscapeHandler()); final ProjectAbstractTreeStructureBase treeStructure = createProjectTreeStructure(); panel.setBuilder(new ProjectListBuilder(project, panel, treeStructure, AlphaComparator.INSTANCE, true)); panel.setProjectTreeStructure(treeStructure); final FocusAdapter focusListener = new FocusAdapter() { @Override public void focusGained(final FocusEvent e) { updateToolWindowTitle(panel); } }; final JList list = panel.getList(); list.addFocusListener(focusListener); list.getSelectionModel().addListSelectionListener(mySelectionListener); list.getModel().addListDataListener(myListDataListener); Disposer.register(this, new Disposable() { @Override public void dispose() { list.removeFocusListener(focusListener); list.getSelectionModel().removeListSelectionListener(mySelectionListener); list.getModel().removeListDataListener(myListDataListener); } }); return panel; }