Bug 107308 - WebKitDownload notify::progress signal is not emitted when it should
Summary: WebKitDownload notify::progress signal is not emitted when it should
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Linux
: P2 Normal
Assignee: Nobody
URL: http://bugs.sugarlabs.org/ticket/4385
Depends on:
Reported: 2013-01-18 11:16 PST by Manuel Kaufmann
Modified: 2017-03-11 10:46 PST (History)
2 users (show)

See Also:

Test Case (2.02 KB, text/x-python)
2013-01-18 11:16 PST, Manuel Kaufmann
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Manuel Kaufmann 2013-01-18 11:16:34 PST
Created attachment 183512 [details]
Test Case


Working on Sugar's Browse Activity I found that "notify::progress" signal from WebKitDownload is not emitted when it should. The first time that you download a file using WebKitDownload this signal is emitted without any problem, but the second time that you download a file (it could be the same one) that signal is no emitted at all if the first download was successful. Instead, if the downloading progress was canceled at any time (let's say 20%) the "notify::progress" signal will be emitted when the progress property reaches the last value (in this case 20%).

I'm attaching a Test Case done in Python and I can confirm this behaviour using Epiphany that the first time that I click on a link to download a file the progress is showed and the second time it just says "Starting..." until the file is fully downloaded.

I went to the code and I saw this comment. Maybe it has something to do with this.

 - ./Source/WebKit/gtk/webkit/webkitdownload.cpp L325

     * WebKitDownload:progress:
     * Determines the current progress of the download. Notice that,
     * although the progress changes are reported as soon as possible,
     * the emission of the notify signal for this property is
     * throttled, for the benefit of download managers. If you care
     * about every update, use WebKitDownload:current-size.
     * Since: 1.1.2

Thanks, and I hope it helps