private void FileSelected(FileSelectedMessage obj) { if (obj.FilePath.EndsWith("txt")) { var pp = new TextPresenter(obj.FilePath); var tabItem = new TabItem {Header = obj.FilePath, Content = pp}; var region = _regionManager.GetRegion("mainTabs"); region.AddView(tabItem); region.Activate(tabItem); } }
private void FileSelected(FileSelectedMessage obj) { if (obj.FilePath.EndsWith("txt")) { var pp = new TextPresenter(obj.FilePath); var tabItem = new TabItem { Header = obj.FilePath, Content = pp }; var region = _regionManager.GetRegion("mainTabs"); region.AddView(tabItem); region.Activate(tabItem); } }