2018-12-04 15:12:21 +00:00
|
|
|
'use strict'
|
|
|
|
|
|
|
|
// Public-facing API methods.
|
|
|
|
exports.syncMethods = new Set([
|
|
|
|
'getURL',
|
|
|
|
'getTitle',
|
|
|
|
'isLoading',
|
|
|
|
'isLoadingMainFrame',
|
|
|
|
'isWaitingForResponse',
|
|
|
|
'stop',
|
|
|
|
'reload',
|
|
|
|
'reloadIgnoringCache',
|
|
|
|
'canGoBack',
|
|
|
|
'canGoForward',
|
|
|
|
'canGoToOffset',
|
|
|
|
'clearHistory',
|
|
|
|
'goBack',
|
|
|
|
'goForward',
|
|
|
|
'goToIndex',
|
|
|
|
'goToOffset',
|
|
|
|
'isCrashed',
|
|
|
|
'setUserAgent',
|
|
|
|
'getUserAgent',
|
|
|
|
'openDevTools',
|
|
|
|
'closeDevTools',
|
|
|
|
'isDevToolsOpened',
|
|
|
|
'isDevToolsFocused',
|
|
|
|
'inspectElement',
|
|
|
|
'setAudioMuted',
|
|
|
|
'isAudioMuted',
|
|
|
|
'isCurrentlyAudible',
|
|
|
|
'undo',
|
|
|
|
'redo',
|
|
|
|
'cut',
|
|
|
|
'copy',
|
|
|
|
'paste',
|
|
|
|
'pasteAndMatchStyle',
|
|
|
|
'delete',
|
|
|
|
'selectAll',
|
|
|
|
'unselect',
|
|
|
|
'replace',
|
|
|
|
'replaceMisspelling',
|
|
|
|
'findInPage',
|
|
|
|
'stopFindInPage',
|
|
|
|
'downloadURL',
|
2019-02-01 18:44:24 +00:00
|
|
|
'inspectSharedWorker',
|
2018-12-04 15:12:21 +00:00
|
|
|
'inspectServiceWorker',
|
|
|
|
'showDefinitionForSelection',
|
2019-01-21 07:40:27 +00:00
|
|
|
'getZoomFactor',
|
|
|
|
'getZoomLevel',
|
2018-12-04 15:12:21 +00:00
|
|
|
'setZoomFactor',
|
|
|
|
'setZoomLevel'
|
|
|
|
])
|
|
|
|
|
2019-06-17 09:10:02 +00:00
|
|
|
exports.asyncMethods = new Set([
|
2019-07-10 13:20:28 +00:00
|
|
|
'loadURL',
|
2019-06-17 09:10:02 +00:00
|
|
|
'capturePage',
|
|
|
|
'executeJavaScript',
|
2018-12-04 15:12:21 +00:00
|
|
|
'insertCSS',
|
|
|
|
'insertText',
|
2019-06-17 15:39:36 +00:00
|
|
|
'removeInsertedCSS',
|
2018-12-04 15:12:21 +00:00
|
|
|
'send',
|
|
|
|
'sendInputEvent',
|
|
|
|
'setLayoutZoomLevelLimits',
|
|
|
|
'setVisualZoomLevelLimits',
|
2019-06-17 09:10:02 +00:00
|
|
|
'print',
|
2019-02-11 19:20:04 +00:00
|
|
|
'printToPDF'
|
2019-01-17 20:08:54 +00:00
|
|
|
])
|