---
title: "webView(_:dragSourceActionMaskFor:)"
framework: webkit
role: symbol
role_heading: Instance Method
path: "webkit/webuidelegate/webview(_:dragsourceactionmaskfor:)"
---

# webView(_:dragSourceActionMaskFor:)

Returns a mask indicating which drag-source actions are allowed for a drag that begins at the specified location.

## Declaration

```swift
optional func webView(_ webView: WebView!, dragSourceActionMaskFor point: NSPoint) -> Int
```

## Parameters

- `webView`: The web view that sent the message.
- `point`: The point at which the drag began, specified in the coordinates of the web view.

## Return Value

Return Value A mask indicating which drag-source actions are allowed. (Note that the return value changed from an unsigned int to an NSUInteger in OS X v10.5.) See WebDragSourceAction for a list of return values.

## Discussion

Discussion This method is called after the user has begun a drag from a point in a web view. This method can be invoked multiple times while content is dragged from the sending web view. When the content is dropped, the sender sends webView(_:willPerform:from:with:) to the receiver. If you do not implement this method, it returns (WebDragSourceActionAny & ~WebDragSourceActionLink) if the cursor is in an editable part of the web view; otherwise, it returns any.

## See Also

### Controlling Drag Behavior

- [webView(_:dragDestinationActionMaskFor:)](webkit/webuidelegate/webview(_:dragdestinationactionmaskfor:).md)
- [webView(_:willPerform:for:)](webkit/webuidelegate/webview(_:willperform:for:).md)
- [webView(_:willPerform:from:with:)](webkit/webuidelegate/webview(_:willperform:from:with:).md)
