static void RegenerateRows( ListViewItemIds <RepObjectInfo> listViewItemIds, HistoryRevisionList revisions, TreeViewItem rootItem, List <TreeViewItem> rows) { ClearRows(rootItem, rows); if (revisions.GetCount() == 0) { return; } foreach (RepObjectInfo objectInfo in revisions.GetRevisions()) { int objectId; if (!listViewItemIds.TryGetInfoItemId(objectInfo, out objectId)) { objectId = listViewItemIds.AddInfoItem(objectInfo); } HistoryListViewItem changesetListViewItem = new HistoryListViewItem(objectId, objectInfo); rootItem.AddChild(changesetListViewItem); rows.Add(changesetListViewItem); } }
internal void BuildModel( HistoryRevisionList historyRevisionList, long loadedRevisionId) { mListViewItemIds.Clear(); mRevisionsList = historyRevisionList; mLoadedRevisionId = loadedRevisionId; }
void HistoryViewLogic.IHistoryView.UpdateData( HistoryRevisionList list, long loadedRevisionId) { mHistoryListView.BuildModel(list, loadedRevisionId); mHistoryListView.Refilter(); mHistoryListView.Sort(); mHistoryListView.Reload(); }