2018-12-04 15:12:21 +00:00
|
|
|
// Public-facing API methods.
|
2019-07-17 17:23:52 +00:00
|
|
|
export const syncMethods = new Set([
|
2018-12-04 15:12:21 +00:00
|
|
|
'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'
|
2020-03-20 20:28:31 +00:00
|
|
|
]);
|
2018-12-04 15:12:21 +00:00
|
|
|
|
2020-03-03 22:25:14 +00:00
|
|
|
export const properties = new Set([
|
|
|
|
'audioMuted',
|
|
|
|
'userAgent',
|
|
|
|
'zoomLevel',
|
|
|
|
'zoomFactor',
|
|
|
|
'frameRate'
|
2020-03-20 20:28:31 +00:00
|
|
|
]);
|
2020-03-03 22:25:14 +00:00
|
|
|
|
2019-07-17 17:23:52 +00:00
|
|
|
export const asyncMethods = new Set([
|
2019-07-10 13:20:28 +00:00
|
|
|
'loadURL',
|
2019-06-17 09:10:02 +00:00
|
|
|
'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'
|
2020-03-20 20:28:31 +00:00
|
|
|
]);
|