void (ActionEvent e) { if (myPathField == null) { assert false; return; } PropertiesComponent component = PropertiesComponent.getInstance(myProject); String pathToStart = myPathField.getText(); if (StringUtil.isEmpty(pathToStart)) { pathToStart = component.getValue(PROJECT_FILE_TO_START_WITH_KEY); } VirtualFile fileToStart = null; if (!StringUtil.isEmpty(pathToStart)) { fileToStart = LocalFileSystem.getInstance().findFileByPath(pathToStart); } VirtualFile file = FileChooser.chooseFile(myDescriptor, myProject, fileToStart); if (file != null) { String path = ExternalSystemApiUtil.getLocalFileSystemPath(file); myPathField.setText(path); component.setValue(PROJECT_FILE_TO_START_WITH_KEY, path); } }