Bug 1973726 - Set DOM file path for webkitRelativePath. r=sefeng,geckoview-reviewers,webidl,smaug,ohall
Actually, there is no way to set webkitRelativePath from JavaScript.
Since GeckoView's folder picker handles virtual file data, we need to
set relative path from JavaScript directly.
A content URI of System storage document provider only allow file data
access from file/folder picker, so there is no way to test it on
geckoivew-junit.
Also, after landing bug 1591640, GVE always crash when using folder
picker. So this includes a fix for it.
Differential Revision: https://phabricator.services.mozilla.com/D255615
Copyright (c) 2017 Plain contributorsPermission is hereby granted, free of charge, to anyperson obtaining a copy of this software and associateddocumentation files (the "Software"), to deal in theSoftware without restriction, including withoutlimitation the rights to use, copy, modify, merge,publish, distribute, sublicense, and/or sell copies ofthe Software, and to permit persons to whom the Softwareis furnished to do so, subject to the followingconditions:The above copyright notice and this permission noticeshall be included in all copies or substantial portionsof the Software.THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OFANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITEDTO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR APARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENTSHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANYCLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTIONOF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF ORIN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHERDEALINGS IN THE SOFTWARE.