downloadRequested doesn’t expose raw data if already available locally
Bug #1491299 reported by
Olivier Tilloy
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Oxide |
New
|
Undecided
|
Unassigned |
Bug Description
The context menu exposes a saveMedia() method that allows downloading the associated media element.
In the case of an image, when invoked there is a good chance that the image has already been downloaded to be rendered by the WebView, so feeding its URL to the downloadRequested signal means that the image would be downloaded again, which is sub-optimal, especially when on a metered connection.
For images, there should be a way to get at the raw data without re-downloading it, if available.
For canvas elements, the downloadRequested signal could expose a data: URI embedding the image data.
Not sure whether the same applies to video/audio.
To post a comment you must log in.
For canvas elements, the URI we get with the downloadRequested signal is already of the form "data:image/ png;base64, …", so that at least is covered.