private void AddAllTraceSourcesNotPresent()
        {
            if (SourceSettings == null)
            {
                SourceSettings = new ObservableCollection <TraceSourceSetting>();
            }

            var source_setting_names = (from source in SourceSettings
                                        select source.Name).ToList();
            var source_names = (from source in App.AllTraceSources
                                select source.Name).ToList();

            foreach (var name in source_setting_names)
            {
                int existing_index = source_names.BinarySearch(name);
                if (existing_index < 0)
                {
                    continue;
                }

                source_names.RemoveAt(existing_index);
            }

            foreach (var name in source_names)
            {
                var setting = new TraceSourceSetting();
                setting.Name = name;

                SourceSettings.Add(setting);
            }
        }
        public TraceSourceSetting Clone()
        {
            var copy = new TraceSourceSetting();

            copy.mName     = this.Name;
            copy.mLevel    = this.Level;
            copy.mDisabled = this.Disabled;
            return(copy);
        }
 public void Sync(TraceSourceSetting src)
 {
     this.Name     = src.Name;
     this.Level    = src.Level;
     this.Disabled = src.Disabled;
 }