Exemple #1
0
 protected virtual void OnAfterCheck(CheckBoxEventArgs args)
 {
     if (AfterCheck != null)
     {
         AfterCheck(this, args);
     }
 }
Exemple #2
0
        public void SetItemCheckState(object item, CheckBoxState newCheckState)
        {
            CheckBoxEventArgs args = new CheckBoxEventArgs(item, GetItemCheckState(item), newCheckState);

            if (BeforeCheck != null)
            {
                BeforeCheck(this, args);
            }

            _checkStates [item] = args.NewState;
            if (args.OldState != args.NewState)
            {
                OnAfterCheck(args);
                OwnerControl.InvalidateItem(item);
            }
        }