Welcome Guest Search | Active Topics | Sign In | Register

25.1.22 Multiple Downloads Options
Fabien
Posted: Wednesday, March 26, 2025 6:15:19 AM
Rank: Advanced Member
Groups: Member

Joined: 7/21/2014
Posts: 133
Hi,

We have had a problem since upgrading to version 25 (25.1.22): multiple downloads no longer seem to work.

You can test this: https://fab-c.github.io/multidownloads.html. The Download buttons work fine, but the "Download All" button only downloads one of the two files.

It works correctly in Chrome and was also functioning in EO.WebBrowser version 24.0.49.0.

Thank you in advance for addressing this issue and releasing a fix.
Fabien
Posted: Wednesday, March 26, 2025 6:17:27 AM
Rank: Advanced Member
Groups: Member

Joined: 7/21/2014
Posts: 133
I forgot to mention that we tested with .SetFeatureState(EO.WebEngine.EngineFeature.MultipleDownloads, True), but it doesn't change the behavior.

Even the NewWindow event doesn't seem to be triggered.

Thanks !
eo_support
Posted: Sunday, March 30, 2025 3:56:49 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,322
Hi,

Sorry about the delay. The download urls in the sample page no longer seem to work.

Multi-download is enabled by default. So SetFeatureState(EO.WebEngine.EngineFeatures.MultipleDownloads, true) has no effect. The difference between version 25.1.22 and previous v25 build is previous v25 build would display a permission bubble asking user whether to allow multi-download, but since version 25.1.22 whether to allow multi-download is explicitly controlled by EngineFeatures.MultipleDownloads.

It appears that the problem is related to the code using window.open instead of link.click method. We tested multiple downloads feature with this test page:

https://sindresorhus.com/multi-download/

This page dynamically creates HTML A element and then call the element's click method to initialize download and the above page works correctly with build 25.1.22.

If you have a working test page that uses window.open method and it does work correctly in Google Chrome, please send it us and we will test it again.

Thanks!
Fabien
Posted: Monday, March 31, 2025 3:53:36 AM
Rank: Advanced Member
Groups: Member

Joined: 7/21/2014
Posts: 133
Hello,
We have fixed the URLs on the test page, you can try again (https://fab-c.github.io/multidownloads.html)

Indeed, the issue may be caused by the chaining of window.open rather than multiple downloads. In any case, it was working on previous versions and on Chrome. The problem might be that EO.WebBrowser does not handle the permission request for multiple popups?
eo_support
Posted: Monday, March 31, 2025 12:21:52 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,322
Hi,

We have looked into this. Please try to use the HTML A element click() method to perform multiple downloads.

The reason that window.open method didn't work properly is because Chromium's built-in popup blocker. Chromium's built-in popup blocker only allows one "activation" per click. This means one click one new window. The second new window will be automatically blocked since there are no more clicks to associate it with.

Google Chrome does have the UI for end user to override this policy but EO.WebBrowser does not have any UI/options for you to do so. The only option is to disable the popup blocker entirely with EngineOption.ExtraCommandLineArgs:

Code: C#
EO.WebEngine.EngineOptions.Default.ExtraCommandLineArgs = "--disable-popup-blocking";


However this will disable the popup blocker completely so it may not be what you wanted.

Additionally, even with the above ExtraCommandLineArgs option, the TabbedBrowser sample application still will not download both files correctly. This is because the sample application only attach download related events (BeforeDownload/DownloadCompleted/DownloadCancelled) when the WebView is actively selected --- since the tabbed UI only have a single selected WebView at any given time, so downloaded events are only handled for a single WebView instead of both.

Considering that A element click() does not either of the above restrictions, that would be the recommended method.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.