/// <summary> Обработчик изменения контактов </summary> private void InstanceOnListModelContactChanged(List <ModelContact> listChangedModelContact, List <ModelContact> listDeletedModelContact) { var modelCallHistoryDetail = DataSourceCall.GetChangedModelCallHistoryDetail(_modelCallHistoryPeerObj); Action action = () => { ModelCallHistoryPeerObj.ListModelCallHistoryEntry = modelCallHistoryDetail.ListModelCallHistoryPeer.First().GetDeepCopy().ListModelCallHistoryEntry; }; CurrentDispatcher.BeginInvoke(action); }
/// <summary> Обработчик изменения истории вызовов </summary> private void OnModelCallHistoryChanged(object sender, ModelCallHistory modelCallHistory) { if (modelCallHistory.ListModelCallHistoryPeer.Any(obj => obj.ModelPeerObj.Id == _modelCallHistoryPeerObj.ModelPeerObj.Id)) { var modelCallHistoryDetail = DataSourceCall.GetChangedModelCallHistoryDetail(_modelCallHistoryPeerObj); Action action = () => { ModelCallHistoryPeerObj.ListModelCallHistoryEntry = modelCallHistoryDetail.ListModelCallHistoryPeer.First().GetDeepCopy().ListModelCallHistoryEntry; }; CurrentDispatcher.BeginInvoke(action); } }