If webView:dragSourceActionMaskForPoint: (WebUIDelegate protocol) is implemented and returns a mask in which the WebDragSourceActionDHTML bit is clear, dragging does not work when dragging ordinary text, links, etc. from that WebView. - If another WebView in the same app (without this bit cleared) has already performed a successful drag, then the pasteboard will contain that previous drag's data. - If no other WebView has already performed a successful drag operation, then DragController crashes, with a trashed stack. To reproduce, simply implement the following in a WebUIDelegate: - (unsigned)webView:(WebView *)sender dragSourceActionMaskForPoint:(NSPoint)point { return (WebDragSourceActionAny & ~WebDragSourceActionDHTML); } Bug does not occur in WebKit released with OS X 10.4 Tiger. I don't know at what point it turned up in the nightlies. It is present in rev. 21322 of 2007-05-09.
<rdar://problem/5335265> Reproduced by bludgeoning WebDragClient WebCore::DragSourceAction WebDragClient::dragSourceActionMaskForPoint(const IntPoint& windowPoint) { return (DragSourceAction)(WebDragSourceActionAny & ~WebDragSourceActionDHTML);/* NSPoint viewPoint = [m_webView convertPoint:windowPoint fromView:nil]; return (DragSourceAction)[[m_webView _UIDelegateForwarder] webView:m_webView dragSourceActionMaskForPoint:viewPoint];*/ } We end up with a null clipboard, which is worrisome...
Created attachment 15510 [details] Fix non-dhtml dragging Righto, the problem was that we didn't preflight the clipboard unless we thought we might be performing a dhtml drag, which is an entirely unnecessary (and incorrect) requirement.
Landed in r24283