protected virtual void RaiseSubmitChanges(TypeSubmitChanges type, object oldItem, object newItem, int index)
        {
            SubmitChangesArgs   args   = new SubmitChangesArgs(TypeSubmitChanges.Add, oldItem, newItem, index);
            SubmitChangesResult result = new SubmitChangesResult(args, SubmitChangesFeedback);

            SubmitChanges(args, result);
        }
        protected override void SubmitChangesFeedback(SubmitChangesResult resultFeedback)
        {
            if (resultFeedback.Cancel)
            {
                return;
            }
            SubmitChangesArgs args = (SubmitChangesArgs)resultFeedback.RequestArgs;

            UpdateCount();
            if (args.Type == TypeSubmitChanges.Replace || args.Type == TypeSubmitChanges.Update)
            {
                UpdateData(args.Index, 1);
            }
        }
Exemplo n.º 3
0
 internal SubmitChangesResult(SubmitChangesArgs requestArgs, SubmitChangesFeedback feedback)
     : base(requestArgs)
 {
     Feedback = feedback;
 }
Exemplo n.º 4
0
 void OnSubmitChanges(SubmitChangesArgs args, SubmitChangesResult feedback)
 {
     SubmitChanges(args, feedback);
 }