Esempio n. 1
0
        public ConvertOperation(IDataObject data, Operation allowedOp)
        {
            allowedOp &= data.GetAllowedConvertOp();

            this.data      = new ConversionData(data);
            this.allowedOp = allowedOp;
        }
Esempio n. 2
0
 public void MarkObjectHandled(object data)
 {
     if (data == null)
     {
         return;
     }
     if (data is IContentRef)
     {
         data = (data as IContentRef).Res;
     }
     this.handledObj.Add(data);
 }
Esempio n. 3
0
 public bool IsObjectHandled(object data)
 {
     if (data == null)
     {
         return(false);
     }
     if (data is IContentRef)
     {
         data = (data as IContentRef).Res;
     }
     return(this.handledObj.Contains(data));
 }
Esempio n. 4
0
        public ConvertOperation(IEnumerable <object> data, Operation allowedOp)
        {
            DataObject dataObj = new DataObject();

            foreach (object obj in data)
            {
                if (obj == null)
                {
                    continue;
                }
                dataObj.SetData(obj.GetType(), obj);
            }
            this.data      = new ConversionData(dataObj);
            this.allowedOp = allowedOp;
        }