Revert "Merge pull request #8724 from electron/defer_load_url"
Possible cause for #9121 This reverts commit886b47e713
, reversing changes made to479af3c9e2
.
This commit is contained in:
parent
dfab1043d9
commit
50ac7b2edd
4 changed files with 16 additions and 139 deletions
|
@ -298,11 +298,6 @@ describe('BrowserWindow module', function () {
|
|||
w.loadURL(`data:image/png;base64,${data}`)
|
||||
})
|
||||
|
||||
it('should not crash when there is a pending navigation entry', function (done) {
|
||||
ipcRenderer.once('navigated-with-pending-entry', () => done())
|
||||
ipcRenderer.send('navigate-with-pending-entry', w.id)
|
||||
})
|
||||
|
||||
describe('POST navigations', function () {
|
||||
afterEach(() => {
|
||||
w.webContents.session.webRequest.onBeforeSendHeaders(null)
|
||||
|
|
|
@ -329,24 +329,6 @@ ipcMain.on('handle-unhandled-rejection', (event, message) => {
|
|||
})
|
||||
})
|
||||
|
||||
ipcMain.on('navigate-with-pending-entry', (event, id) => {
|
||||
const w = BrowserWindow.fromId(id)
|
||||
|
||||
w.webContents.on('did-start-loading', () => {
|
||||
w.loadURL('about:blank')
|
||||
})
|
||||
|
||||
w.webContents.on('did-navigate', (e, url) => {
|
||||
if (url === 'about:blank') {
|
||||
event.sender.send('navigated-with-pending-entry')
|
||||
}
|
||||
})
|
||||
|
||||
w.webContents.session.clearHostResolverCache(() => {
|
||||
w.loadURL('http://host')
|
||||
})
|
||||
})
|
||||
|
||||
ipcMain.on('crash-service-pid', (event, pid) => {
|
||||
process.crashServicePid = pid
|
||||
event.returnValue = null
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue