Skip to content

Commit

Permalink
feat(webkit): roll webkit to 1124 (#736)
Browse files Browse the repository at this point in the history
  • Loading branch information
pavelfeldman authored Jan 30, 2020
1 parent 44829d6 commit ce72198
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"playwright": {
"chromium_revision": "733125",
"firefox_revision": "1020",
"webkit_revision": "1120"
"webkit_revision": "1124"
},
"scripts": {
"ctest": "cross-env BROWSER=chromium node test/test.js",
Expand Down
10 changes: 5 additions & 5 deletions src/webkit/wkPage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import * as dom from '../dom';
import * as network from '../network';
import { WKSession } from './wkConnection';
import { Events } from '../events';
import { WKExecutionContext, EVALUATION_SCRIPT_URL } from './wkExecutionContext';
import { WKExecutionContext } from './wkExecutionContext';
import { WKInterceptableRequest } from './wkInterceptableRequest';
import { WKWorkers } from './wkWorkers';
import { Page, PageDelegate, Coverage } from '../page';
Expand Down Expand Up @@ -101,7 +101,7 @@ export class WKPage implements PageDelegate {
session.send('Page.getResourceTree').then(resourceTreeHandler),
// Resource tree should be received before first execution context.
session.send('Runtime.enable'),
session.send('Page.createIsolatedWorld', { name: UTILITY_WORLD_NAME, source: `//# sourceURL=${EVALUATION_SCRIPT_URL}` }),
session.send('Page.createUserWorld', { name: UTILITY_WORLD_NAME }).catch(_ => {}), // Worlds are per-process
session.send('Console.enable'),
session.send('Page.setInterceptFileChooserDialog', { enabled: true }),
session.send('Network.enable'),
Expand Down Expand Up @@ -295,11 +295,11 @@ export class WKPage implements PageDelegate {
return;
const delegate = new WKExecutionContext(this._session, contextPayload.id);
const context = new dom.FrameExecutionContext(delegate, frame);
if (contextPayload.isPageContext)
if (contextPayload.type === 'normal')
frame._contextCreated('main', context);
else if (contextPayload.name === UTILITY_WORLD_NAME)
else if (contextPayload.type === 'user' && contextPayload.name === UTILITY_WORLD_NAME)
frame._contextCreated('utility', context);
if (contextPayload.isPageContext && frame === this._page.mainFrame())
if (contextPayload.type === 'normal' && frame === this._page.mainFrame())
this._mainFrameContextId = contextPayload.id;
this._contextIdToContext.set(contextPayload.id, context);
}
Expand Down

0 comments on commit ce72198

Please sign in to comment.