예제 #1
0
        // 从集合中和视觉上同时删除
        public void PhysicalDeleteItem(
            OrderItem orderitem)
        {
            // 从listview中消失
            orderitem.DeleteFromListView();

            this.Remove(orderitem);
        }
예제 #2
0
        public new void Clear()
        {
            for (int i = 0; i < this.Count; i++)
            {
                OrderItem item = this[i];
                item.DeleteFromListView();
            }

            base.Clear();
        }
예제 #3
0
        // 标记删除
        public void MaskDeleteItem(
            bool bRemoveFromList,
            OrderItem orderitem)
        {
            if (orderitem.ItemDisplayState == ItemDisplayState.New)
            {
                PhysicalDeleteItem(orderitem);
                return;
            }


            orderitem.ItemDisplayState = ItemDisplayState.Deleted;
            orderitem.Changed          = true;

            // 从listview中消失?
            if (bRemoveFromList == true)
            {
                orderitem.DeleteFromListView();
            }
            else
            {
                orderitem.RefreshListView();
            }
        }
예제 #4
0
파일: OrderItem.cs 프로젝트: paopaofeng/dp2
        // 从集合中和视觉上同时删除
        public void PhysicalDeleteItem(
            OrderItem orderitem)
        {
            // 从listview中消失
            orderitem.DeleteFromListView();

            this.Remove(orderitem);
        }
예제 #5
0
파일: OrderItem.cs 프로젝트: paopaofeng/dp2
        // 标记删除
        public void MaskDeleteItem(
            bool bRemoveFromList,
            OrderItem orderitem)
        {
            if (orderitem.ItemDisplayState == ItemDisplayState.New)
            {
                PhysicalDeleteItem(orderitem);
                return;
            }


            orderitem.ItemDisplayState = ItemDisplayState.Deleted;
            orderitem.Changed = true;

            // 从listview中消失?
            if (bRemoveFromList == true)
                orderitem.DeleteFromListView();
            else
            {
                orderitem.RefreshListView();
            }
        }