// Изменен выбранный элемент списка установленного ПО private void ListViewSelectionChanged(object sender, EventArgs e) { if (_installedSoftView != null && _installedSoftView.View != null && _installedSoftView.View.CurrentItem == null) { if (InstalledSoft.Count > 0) { SelectedListItem = InstalledSoft.First(); } if (InstalledSoftView.Count > 0) { InstalledSoftView.MoveCurrentToFirst(); OnPropertyChanged("DelButtonIsEnable"); } } }
// Загрузка данных private void OnLoadData(object state) { ObservableCollection <Soft> data = (ObservableCollection <Soft>)state; data.ToList().ForEach(x => { initImageIcon(ref x); }); InstalledSoft = data; InstalledSoftView.MoveCurrentToFirst(); OnPropertyChanged("DelButtonIsEnable"); IsEnableSelectPC = true; IsEnableLogin = true; IsEnablePass = true; IsEnableSearchFiel = true; messageEvent -= updateInfoSearchProcess; StatusText = ""; }