public ConvertOperation(IDataObject data, Operation allowedOp) { allowedOp &= data.GetAllowedConvertOp(); this.data = new ConversionData(data); this.allowedOp = allowedOp; }
public void MarkObjectHandled(object data) { if (data == null) { return; } if (data is IContentRef) { data = (data as IContentRef).Res; } this.handledObj.Add(data); }
public bool IsObjectHandled(object data) { if (data == null) { return(false); } if (data is IContentRef) { data = (data as IContentRef).Res; } return(this.handledObj.Contains(data)); }
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; }