public DeferredOperation(
   DeferredOperationAction action,
   int startingIndex,
   IList items )
   : this( action, -1, startingIndex, items )
 {
 }
 public DeferredOperation(
   DeferredOperationAction action,
   bool filteredItemsChanged )
   : this( action, -1, -1, null )
 {
   m_filteredItemsChanged = filteredItemsChanged;
 }
 public DeferredOperation(
   DeferredOperationAction action,
   int newSourceItemCount,
   int newStartingIndex,
   IList newItems,
   int oldStartingIndex,
   IList oldItems )
 {
   // newSourceItemCount is for when we are adding item in a IBindingList
   // It is use to detect that 2 add are in fact only one, because the second one is just for confirming the first one.
   m_action = action;
   m_newSourceItemCount = newSourceItemCount;
   m_newItems = newItems;
   m_newStartingIndex = newStartingIndex;
   m_oldItems = oldItems;
   m_oldStartingIndex = oldStartingIndex;
 }
    public DeferredOperation(
      DeferredOperationAction action,
      int newSourceItemCount,
      int startingIndex,
      IList items )
    {
      // newSourceItemCount is for when we are adding item in a IBindingList
      // It is use to detect we 2 add are in fact only one, bcause the second one is just for confirming the first one.
      m_action = action;
      m_newSourceItemCount = newSourceItemCount;

      switch( action )
      {
        case DeferredOperationAction.Add:
        case DeferredOperationAction.Replace:
          {
            m_newItems = items;
            m_newStartingIndex = startingIndex;
            break;
          }

        case DeferredOperationAction.Remove:
          {
            m_oldItems = items;
            m_oldStartingIndex = startingIndex;
            break;
          }

        case DeferredOperationAction.Refresh:
        case DeferredOperationAction.Resort:
        case DeferredOperationAction.Regroup:
        case DeferredOperationAction.RefreshDistincValues:
          break;

        default:
          {
            throw new ArgumentException( "An attempt was made to use the " + action.ToString() + " action, which is not supported by this constructor." );
          }
      }
    }
示例#5
0
 public DeferredOperation(DeferredOperationAction action, int startingIndex, IList items)
     : this(action, -1, startingIndex, items)
 {
 }
示例#6
0
 public DeferredOperation(DeferredOperationAction action, IList items)
 {
     m_action   = action;
     m_newItems = items;
 }
示例#7
0
 public DeferredOperation(DeferredOperationAction action, object dataItem)
 {
     m_action   = action;
     m_dataItem = dataItem;
 }
示例#8
0
 public DeferredOperation(DeferredOperationAction action, bool filteredItemsChanged)
     : this(action, -1, -1, null)
 {
     m_filteredItemsChanged = filteredItemsChanged;
 }
 public DeferredOperation( DeferredOperationAction action, IList items )
 {
   m_action = action;
   m_newItems = items;
 }
 public DeferredOperation( DeferredOperationAction action, object dataItem )
 {
   m_action = action;
   m_dataItem = dataItem;
 }