FilesApp: support being a file drop target to crostini apps
Add support for FilesApp to be a drop target for files which have originated dragging from other apps such as crostini, plugin vm, or arc. FilesApp seems to be using custom fs/* mime types such as fs/sources for DataTransfer used in drag and drop. This appears to pass around lists of entry URLs as strings. The URLs are later resolved to FileEntry using webkitResolveLocalFileSystemURL. When files are provided from other systems besides FilesApp, the URLs provided are not compatible, but DataTransferItem.webkitGetAsEntry() can be used to get a FileEntry which can be used in the drop-copy operation. This CL now allows DataTransfer with type 'Files', and refactors FileTransferController.PastePlan to allow sourceEntries to be provided as an alternative to sourceURLs. Bug: 1144138 Change-Id: I6b160eef7140d824b816076c71f1bd3a455a4415 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2542938Reviewed-by:Luciano Pacheco <lucmult@chromium.org> Commit-Queue: Joel Hockey <joelhockey@chromium.org> Cr-Commit-Position: refs/heads/master@{#829073}
Showing
Please register or sign in to comment