[iOS DnD] [WK2] WKWebView does not handle drag sessions that exit and re-enter
authorwenson_hsieh@apple.com <wenson_hsieh@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 27 Jun 2017 14:49:20 +0000 (14:49 +0000)
committerwenson_hsieh@apple.com <wenson_hsieh@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 27 Jun 2017 14:49:20 +0000 (14:49 +0000)
commiteced1fae5608518325ae6e805f6b4fced3354abc
tree90eb51144fbf658f1fae0c0f6148968854305373
parentfee8bd698b22004c6462f7e1046d6a8bfb9e7420
[iOS DnD] [WK2] WKWebView does not handle drag sessions that exit and re-enter
https://bugs.webkit.org/show_bug.cgi?id=173856
<rdar://problem/32957100>

Reviewed by Ryosuke Niwa.

Upon exiting a WKContentView, the dropSession tracked by _dataInteractionState is not cleared out. If the drag
session re-enters the WKWebView, a _different_ UIDropSession is sent to the drop delegate, causing us to bail
from handling the session altogether in -dropInteraction:canHandleSession:. To fix this, we need to clear out
the dropSession when the drag session exits the view.

* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView dropInteraction:sessionDidExit:]):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@218834 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm