private NSDragOperation SendRawDragEvent(NSDraggingInfo sender, RawDragEventType type) { Action <RawInputEventArgs> input = _tl.Input; IDragDropDevice dragDevice = _tl._dragDevice; IInputRoot root = _tl?.InputRoot; if (root == null || dragDevice == null || input == null) { return(NSDragOperation.None); } var dragOp = DraggingInfo.ConvertDragOperation(sender.DraggingSourceOperationMask); DraggingInfo info = new DraggingInfo(sender); var pt = TranslateLocalPoint(info.Location); var args = new RawDragEvent(dragDevice, type, root, pt, info, dragOp); input(args); return(DraggingInfo.ConvertDragOperation(args.Effects)); }
public override void DraggedImageEndedAtOperation(NSImage image, CGPoint screenPoint, NSDragOperation operation) { _result.OnNext(DraggingInfo.ConvertDragOperation(operation)); _result.OnCompleted(); }
public override NSDragOperation DraggingSourceOperationMaskForLocal(bool flag) { return(DraggingInfo.ConvertDragOperation(_allowedEffects)); }