public void editReplaceInProjectMenuItemActionPerformed() {
    if (!Core.getProject().isProjectLoaded()) return;

    SearchWindowController search = new SearchWindowController(SearchMode.REPLACE);
    mainWindow.addSearchWindow(search);

    search.makeVisible(getTrimmedSelectedTextInMainWindow());
  }
  void findInProjectReuseLastWindow() {
    if (!Core.getProject().isProjectLoaded()) {
      return;
    }

    SearchWindowController search = mainWindow.peekLastSearchWindow();
    if (search == null) {
      editFindInProjectMenuItemActionPerformed();
    } else {
      search.makeVisible(getTrimmedSelectedTextInMainWindow());
    }
  }