Add support for overriding default drops in editable elements with two-step drops. See performsTwoStepPaste: for reference.
Created attachment 312080 [details] Patch
<rdar://problem/32590174>
Created attachment 312132 [details] Patch
Can this be tested?
(In reply to Sam Weinig from comment #4) > Can this be tested? Unfortunately, I'm not sure how to test this. One thing I thought of is also adding injected bundle SPI to WK2 to handle the two-step paste, and then add a TestWebKitAPI test that exercises the codepath in WebCore. This would allow us to test the WebCore change (which is really the meat of what changed). However, this approach would also mean that this new injected bundle SPI would only be used for testing -- at least, until Mail adopts WK2 :). Perhaps it's not a bad idea to add an injected bundle version of performTwoStepDrop: if we know we'll need it for WK2 soon anyways. What do you think?
I think you should add the API test you mention, as discussed in person.
Created attachment 312454 [details] Add WK2 injected bundle support and tests.
Attachment 312454 [details] did not pass style-queue: ERROR: Source/WebKit2/WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:663: This { should be at the end of the previous line [whitespace/braces] [4] Total errors found: 1 in 24 files If any of these errors are false positives, please file a bug against check-webkit-style.
Created attachment 312458 [details] Fix WebKitTestRunner build.
Attachment 312458 [details] did not pass style-queue: ERROR: Source/WebKit2/WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:663: This { should be at the end of the previous line [whitespace/braces] [4] Total errors found: 1 in 25 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 312458 [details] Fix WebKitTestRunner build. Clearing flags on attachment: 312458 Committed r218014: <http://trac.webkit.org/changeset/218014>