public override void LoadContentData() { _resourceManager.LoadGraphicResources(); if (_contentLoaded) { return; } UsersList.Load(_resourceManager.DataUsersFile); CoverLists.Load(_resourceManager.DataCoverFile); ClientGoalsLists.Load(_resourceManager.DataClientGoalsFile); LeadoffStatementLists.Load(_resourceManager.DataLeadoffStatementFile); TargetCustomersLists.LoadCombinedData(_resourceManager.DataTargetCustomersFile); SimpleSummaryLists.Load(_resourceManager.DataSimpleSummaryFile); _contentLoaded = true; }
public override void LoadContentData() { _resourceManager.LoadGraphicResources(); if (_contentLoaded) { return; } if (_resourceManager.SettingsFile.ExistsLocal()) { var document = new XmlDocument(); document.Load(_resourceManager.SettingsFile.LocalPath); foreach (var tabConfigNode in document.SelectNodes(@"//Settings/Tab")?.OfType <XmlNode>().ToArray() ?? new XmlNode[] { }) { var tabId = tabConfigNode.SelectSingleNode("Type")?.InnerText?.ToLower(); StarTopTabInfo tabInfo; switch (tabId) { case "default": tabInfo = new CleanslateTabInfo(); break; case "cover": tabInfo = new CoverTabInfo(); break; case "cna": tabInfo = new CNATabInfo(); break; case "fishing": tabInfo = new FishingTabInfo(); break; case "customer": tabInfo = new CustomerTabInfo(); break; case "share": tabInfo = new ShareTabInfo(); break; case "roi": tabInfo = new ROITabInfo(); break; case "market": tabInfo = new MarketTabInfo(); break; case "video": tabInfo = new VideoTabInfo(); break; case "audience": tabInfo = new AudienceTabInfo(); break; case "solution": tabInfo = new SolutionTabInfo(); break; case "closers": tabInfo = new ClosersTabInfo(); break; default: throw new ArgumentOutOfRangeException("Star tab type is not defined"); } tabInfo.LoadData(tabConfigNode, _resourceManager); TabsInfo.Add(tabInfo); } } UsersList.Load(_resourceManager.DataUsersFile); ClientGoalsLists.Load(_resourceManager.DataClientGoalsFile); TargetCustomersLists.LoadCombinedData(_resourceManager.DataTargetCustomersFile); _contentLoaded = true; }