void (@NotNull DocumentEvent e) { JComboBox comboBox = getComboBox(); DirectoryChooser.ItemWrapper selectedItem = (DirectoryChooser.ItemWrapper)comboBox.getSelectedItem(); VirtualFile initialTargetDirectorySourceRoot = selectedItem != null && selectedItem != DirectoryChooser.ItemWrapper.NULL ? fileIndex.getSourceRootForFile(selectedItem.getDirectory().getVirtualFile()) : sourceRoot; setComboboxModel(initialTargetDirectorySourceRoot, selection.get(), false); }