Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable an app to display a custom "interrupted" dialog #105

Open
ctrlaltdavid opened this issue Feb 13, 2020 · 2 comments
Open

Enable an app to display a custom "interrupted" dialog #105

ctrlaltdavid opened this issue Feb 13, 2020 · 2 comments

Comments

@ctrlaltdavid
Copy link

Rather than just allowing the 'The download of {filename} was interrupted' system message box text to be customized, enable the app to provide a dialog box styled per the app.

Could perhaps be achieved by one of:
(a) Add an 'onError' optional callback. (No "interrupted" dialog is displayed is this callback is specified.)
(b) Allow a blank string to be specified as the value of 'errorMessage'. (No "interrupted" dialog is displayed if the string is ""; the "interrupted" result can be found by testing the 'state' returned by the 'done' event).

@sindresorhus
Copy link
Owner

I would go with a.

@theogravity
Copy link
Contributor

theogravity commented Mar 23, 2024

I have this feature implemented in my library where you can hook into an error or interrupted callback:

https://github.com/theogravity/electron-dl-manager

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants