Merge pull request #4314 from deepak1556/download_cancel_patch
fix crash when default download is canceled
This commit is contained in:
commit
f624800881
6 changed files with 97 additions and 26 deletions
|
@ -60,7 +60,8 @@ The following events are available on instances of `Session`:
|
|||
|
||||
Emitted when Electron is about to download `item` in `webContents`.
|
||||
|
||||
Calling `event.preventDefault()` will cancel the download.
|
||||
Calling `event.preventDefault()` will cancel the download and `item` will not be
|
||||
available from next tick of the process.
|
||||
|
||||
```javascript
|
||||
session.defaultSession.on('will-download', function(event, item, webContents) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue