public EditPanel(MiirorItemDO miDO) { InitializeComponent(); Source.Content = source; Target.Content = target; if (miDO != null) { isEdit = true; Source.Content = miDO.Source; Target.Content = miDO.Target; FileFilter.Text = miDO.Filtered; Recursive.IsChecked = miDO.IsRecursive; mi.Filtered = miDO.Filtered; mi.Identity = miDO.Identity; mi.IsFolder = miDO.IsFolder; mi.IsRecursive = miDO.IsRecursive; mi.IsWorking = miDO.IsWorking; mi.Source = miDO.Source; mi.Target = miDO.Target; } }
private void EditMonitoring(MiirorItemDO item) { EditPanel ep = new EditPanel(item); ep.Owner = this; MiirorItem mi = ep.ShowModel(); if (string.IsNullOrEmpty(mi.Source) && string.IsNullOrEmpty(mi.Target)) { return; } UpdateMonitorList(mi); BindListBox(); BindProgressBar(); SaveConfig(); }