protected VirtualFile getPomFile(final AnActionEvent pEvent) {
final Project project = getProject(pEvent);
if (project == null)
return null;
final PomManager pomMgr = PomManager.getInstance(getProject(pEvent));
final String[] poms;
if (PomManagerPanel.PLACE.equals(pEvent.getPlace())) {
final PomManagerPanel ui = pomMgr.getToolWindowComponent();
if (ui != null)
poms = ui.getPomsWithSelectedGoals(false);
else
poms = new String[0];
}
else
poms = pomMgr.getFileUrls();
final String pomUrl = PomUtils.selectPom(project, poms, DLG_TITLE, DLG_LABEL);
return pomMgr.getFile(pomUrl);
}