/// <summary> /// Initializes a new instance of the TabFileItem class. /// </summary> /// <param name="fileName"></param> /// <param name="title"></param> public TabFileItem(ShellViewModel viewModel, string fileName, string title, TailService tailService) { _viewModel = viewModel; _fileName = fileName; _title = title; TailService = tailService; }
private TabFileItem LoadFile(string fileName) { var service = new TailService(UserSettings, fileName); service.Changed += (sender, e) => Execute.OnUIThread(() => TailChanged(e)); var item = new TabFileItem(this, fileName, Path.GetFileNameWithoutExtension(fileName), service); item.FollowTail = UserSettings.Tail.AutoFollow; TabFileItems.Add(item); return(item); }