dragColor(_:with:from:)
Drags a color into a destination view from the specified source view.
Declaration
class func dragColor(_ color: NSColor, with event: NSEvent, from sourceView: NSView) -> BoolParameters
- color:
The color to drag.
- event:
The drag event.
- sourceView:
The view from which the color was dragged.
Return Value
Discussion
This method is usually invoked by the mouseDown: method of sourceView. The dragging mechanism handles all subsequent events.
Because it is a class method, dragColor(_:with:from:) can be invoked whether or not the instance of NSColorPanel exists.