Contents

outlineView(_:updateDraggingItemsForDrag:)

Implement this method to enable the table to update dragging items as they are dragged over the view.

Declaration

@MainActor optional func outlineView(_ outlineView: NSOutlineView, updateDraggingItemsForDrag draggingInfo: any NSDraggingInfo)

Parameters

  • outlineView:

    The outline view in which the drag occurs.

  • draggingInfo:

    The dragging info object.

Discussion

Implementing this method is required for multi-image dragging. A typical implementation calls the passed-in dragging info object’s enumerateDraggingItems(options:for:classes:searchOptions:using:) method and sets the dragging item’s imageComponentsProvider property to a proper image based on the content. For NSView-based table views, you can use the NSTableCellView method draggingImageComponents.

See Also

Instance Methods