private void editVariables() {
    ArrayList<Variable> newVariables = updateVariablesByTemplateText();

    EditVariableDialog editVariableDialog =
      new EditVariableDialog(myTemplateEditor, myEditVariablesButton, newVariables, getApplicableContexts());
    if (editVariableDialog.showAndGet()) {
      applyVariables(newVariables);
    }
  }
private void editVariables()