@Nullable
  @RequiresEdt
  public static VirtualFile getSelectedFile(@NotNull Project project) {
    FileEditor fileEditor = FileEditorManager.getInstance(project).getSelectedEditor();
    return fileEditor == null ? null : fileEditor.getFile();
  }
@Nullable
  @RequiresEdt
  public static VirtualFile getSelectedFile(@NotNull Project project)