예제 #1
0
        protected virtual void OnRemoved(PObjectEventArgs e)
        {
            e.PObject.Parent = null;
            var handler = this.Removed;

            if (handler != null)
            {
                handler(this, e);
            }
            OnChanged(EventArgs.Empty);
        }
예제 #2
0
        protected virtual void OnAdded(PObjectEventArgs e)
        {
            e.PObject.Parent = this;
            if (SuppressChangeEvents)
            {
                return;
            }

            var handler = this.Added;

            if (handler != null)
            {
                handler(this, e);
            }
            OnChanged(EventArgs.Empty);
        }