the URL to download
prompt user for a filename
Dowload a given URL to disk
This behaves mostly like downloadUrl, except that this function will use the native messenger in order to move the file to saveAs
.
Note: this requires a native messenger >=0.1.9. Make sure to nativegate for this.
If beginning with a slash, this is the absolute path the document should be moved to. If the first character of the string is a tilda, it will be expanded to an absolute path to the user's home directory. If saveAs begins with any other character, it will be considered a path relative to where the native messenger binary is located (e.g. "$HOME/.local/share/tridactyl" on linux).
Construct an object URL string from a given data URL
This is needed because feeding a data URL directly to downloads.download() causes "Error: Access denied for URL"
the URL to make an object URL from
object URL that can be fed to the downloads API
Download a given URL to disk
Normal URLs are downloaded normally. Data URLs are handled more carefully as it's not allowed in WebExt land to just call downloads.download() on them