/// <summary>
 /// Memory cleanup when this control is unloaded
 /// </summary>
 public override void Dispose()
 {
     CurrentLoadedExport   = null;
     CurrentME2ME3TalkFile = null;
     LoadedStrings?.Clear();
     CleanedStrings?.ClearEx();
 }
        public void LoadFileFromStream(Stream stream)
        {
            UnloadExport();
            //CurrentLoadedFile = filepath;
            CurrentME2ME3TalkFile = new TalkFile();
            CurrentME2ME3TalkFile.LoadTlkDataFromStream(stream);

            LoadedStrings = CurrentME2ME3TalkFile.StringRefs.ToList();                    //This is not binded to so reassigning is fine
            CleanedStrings.ReplaceAll(LoadedStrings.Where(x => x.StringID > 0).ToList()); //remove 0 or null strings.
            editBox.Text = NO_STRING_SELECTED;                                            //Reset ability to save, reset edit box if export changed.
            FileModified = false;
        }
        public override void LoadFile(string filepath)
        {
            UnloadExport();
            CurrentLoadedFile     = filepath;
            CurrentME2ME3TalkFile = new TalkFile();
            CurrentME2ME3TalkFile.LoadTlkData(filepath);

            LoadedStrings = CurrentME2ME3TalkFile.StringRefs.ToList();                    //This is not binded to so reassigning is fine
            CleanedStrings.ReplaceAll(LoadedStrings.Where(x => x.StringID > 0).ToList()); //remove 0 or null strings.
            editBox.Text = NO_STRING_SELECTED;                                            //Reset ability to save, reset edit box if export changed.
            FileModified = false;

            AddRecent(filepath, false);
            SaveRecentList();
            RefreshRecent(true, RFiles);
            Window.GetWindow(this).Title = "TLK Editor - " + filepath;
        }