private void InvokeOnCheckBoxClicking(FileTreeViewControlEventArgs args) { CheckBoxClickingHandler handler = OnCheckBoxClicking; if (handler != null) handler(this, args); }
public void CheckBoxClicked(FileTreeViewControlEventArgs args) { InvokeOnCheckBoxClicked(args); }
void SetIsChecked(bool? value, bool updateChildren, bool updateParent) { try { var args = new FileTreeViewControlEventArgs { CurrentNode = this }; _fileTreeViewEvent.CheckBoxClicking(args); if (args.Handled) return; if (value == _isChecked) return; _isChecked = value; if (updateChildren && _isChecked.HasValue) { if (HasDummyChild) { Children.Remove(DummyChild); LoadChildren(); } foreach (var c in Children) { c.SetIsChecked(_isChecked, true, false); } } if (updateParent && _parent != null) _parent.VerifyCheckState(); RaisePropertyChanged("IsChecked"); } catch (Exception) { //ignored } }