/// <summary> /// Adds a new abbreviation to the list, saves /// and reloads the abbreviation list /// </summary> /// <param name="abbr">abbreviation to add</param> private void addAbbreviation(Abbreviation abbr) { Windows.SetVisible(_abbrForm, false); var operation = new AbbrOperation { InputAbbreviation = abbr, Add = true }; editOrAddAbbreviation(operation); if (!operation.Cancel) { Context.AppAbbreviations.Add(operation.OutputAbbreviation); Context.AppAbbreviations.Save(); Context.AppAbbreviations.Load(); } _abbrForm.LoadAbbreviations(); Windows.SetVisible(_abbrForm, true); }