[Qtwebengine] Quick Download API

Charles Wei chwei at blackberry.com
Fri Dec 6 03:36:10 CET 2013


I've created a trello card at: https://trello.com/c/kAFUyoHA/142-download-api-discussion for this.

Let's decide the API so that we can move forward.

Regards
--Charles


From: Arvid Nilsson
Sent: Thursday, December 05, 2013 6:13 PM
To: qtwebengine at qt-project.org
Cc: Charles Wei; michael.bruning at digia.com
Subject: Quick Download API

Hi there!

For full backward compatibility, widget flavor of QtWebEngine might benefit from a QNetworkAccessManager shim on top of the Chromium HTTP stack, and using the regular QtNetwork types to manage downloads.

For QML, we would like to start discussion on how a QML-friendly download API could look like.

Requirements courtesy of cswei:
1. to control the download (stop , resume, pause, cancel, etc)
2. To get the download state notification ( progress, failure, finished, etc)
3. To initiate a download , like anilsson says:  user press-hold on a link/image, and selects "download" to download a resource
4. Give the application/user the opportunity to specify the storage location, the file name, etc.
5. Special download, like OMA download, download of DRM contents, etc.

I believe all the methods/signals/slots from 1 and 2 could go into a WebEngineDownloadRequest creatable class. Perhaps there will be use for a WebEngineDownloadHandler attached object
I think 3 should be an API on WebEngineView or WebEngineView.experimental: WebEngineView.download(WebEngineDownloadRequest). Also a signal for web-initiated downloads WebEngineView.onDownloadRequested (or possibly go straight to the WebEngineDownloadHandler).
I think 4 could also be in the WebEngineDownloadRequest or WebEngineDownloadHandler

All of the required functionality exists in the Chromium content APIs, we just need to figure out an API.

What do you think?

BR,
/A
---------------------------------------------------------------------
This transmission (including any attachments) may contain confidential information, privileged material (including material protected by the solicitor-client or other applicable privileges), or constitute non-public information. Any use of this information by anyone other than the intended recipient is prohibited. If you have received this transmission in error, please immediately reply to the sender and delete this information from your system. Use, dissemination, distribution, or reproduction of this transmission by unintended recipients is not authorized and may be unlawful.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qtwebengine/attachments/20131206/6c5da107/attachment.html>


More information about the QtWebEngine mailing list