@lvce-editor/shared-process 0.25.10 → 0.25.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/src/parts/AddAccurateMemoryUsage/AddAccurateMemoryUsage.js +7 -8
- package/src/parts/AddSemiColon/AddSemiColon.js +3 -4
- package/src/parts/AppWindow/AppWindow.js +14 -16
- package/src/parts/ApplyEdit/ApplyEdit.js +6 -7
- package/src/parts/Assert/Assert.js +1 -1
- package/src/parts/AttachDebugger/AttachDebugger.ipc.js +4 -6
- package/src/parts/AttachDebugger/AttachDebugger.js +4 -5
- package/src/parts/Authority/Authority.js +1 -1
- package/src/parts/AutoUpdateType/AutoUpdateType.js +4 -4
- package/src/parts/AutoUpdater/AutoUpdater.ipc.js +5 -7
- package/src/parts/AutoUpdater/AutoUpdater.js +31 -31
- package/src/parts/AutoUpdaterAppImage/AutoUpdaterAppImage.ipc.js +5 -7
- package/src/parts/AutoUpdaterAppImage/AutoUpdaterAppImage.js +49 -50
- package/src/parts/AutoUpdaterWindowsNsis/AutoUpdaterWindowsNsis.ipc.js +5 -7
- package/src/parts/AutoUpdaterWindowsNsis/AutoUpdaterWindowsNsis.js +49 -49
- package/src/parts/BulkReplacement/BulkReplacement.ipc.js +4 -6
- package/src/parts/BulkReplacement/BulkReplacement.js +16 -16
- package/src/parts/BulkReplacementContent/BulkReplacementContent.js +26 -27
- package/src/parts/ByteSize/ByteSize.js +4 -4
- package/src/parts/Callback/Callback.js +1 -1
- package/src/parts/Character/Character.js +12 -12
- package/src/parts/ChildProcess/ChildProcess.js +71 -86
- package/src/parts/Clamp/Clamp.js +2 -2
- package/src/parts/Cli/Cli.js +12 -12
- package/src/parts/CliCommandType/CliCommandType.js +11 -11
- package/src/parts/CliHelp/CliHelp.js +8 -9
- package/src/parts/CliInstall/CliInstall.js +24 -24
- package/src/parts/CliLink/CliLink.js +17 -17
- package/src/parts/CliList/CliList.js +15 -18
- package/src/parts/CliModule/CliModule.js +26 -27
- package/src/parts/CliStatus/CliStatus.js +4 -5
- package/src/parts/CliUnlink/CliUnlink.js +17 -17
- package/src/parts/CliVersion/CliVersion.js +7 -8
- package/src/parts/ClipBoard/ClipBoard.ipc.js +5 -7
- package/src/parts/ClipBoard/ClipBoard.js +18 -21
- package/src/parts/ClipBoard/ClipBoardGnome.js +49 -54
- package/src/parts/ClipBoard/ClipBoardNoop.js +10 -12
- package/src/parts/ClipBoard/ClipBoardWindows.js +17 -18
- package/src/parts/CollectTextSearchStdout/CollectTextSearchStdout.js +83 -93
- package/src/parts/ColorTheme/ColorTheme.js +14 -17
- package/src/parts/Command/Command.js +61 -68
- package/src/parts/CommandNotFoundError/CommandNotFoundError.js +7 -8
- package/src/parts/CompareVersion/CompareVersion.js +2 -2
- package/src/parts/ContentSecurityPolicy/ContentSecurityPolicy.ipc.js +4 -6
- package/src/parts/ContentSecurityPolicy/ContentSecurityPolicy.js +6 -7
- package/src/parts/ContentSecurityPolicyDiffWorker/ContentSecurityPolicyDiffWorker.js +2 -0
- package/src/parts/ContentSecurityPolicyDocument/ContentSecurityPolicyDocument.js +9 -10
- package/src/parts/ContentSecurityPolicyState/ContentSecurityPolicyState.js +5 -7
- package/src/parts/ContentSecurityPolicySyntaxHighlightingWorker/ContentSecurityPolicySyntaxHighlightingWorker.js +2 -3
- package/src/parts/ContentSecurityPolicyTerminalWorker/ContentSecurityPolicyTerminalWorker.js +2 -3
- package/src/parts/ContentSecurityPolicyTestWorker/ContentSecurityPolicyTestWorker.js +2 -3
- package/src/parts/ContentSecurityPolicyWorker/ContentSecurityPolicyWorker.js +6 -7
- package/src/parts/CpuProfile/CpuProfile.js +22 -25
- package/src/parts/Crash/Crash.ipc.js +5 -7
- package/src/parts/Crash/Crash.js +8 -11
- package/src/parts/CreatePidMap/CreatePidMap.js +4 -5
- package/src/parts/CreateTestOverview/CreateTestOverview.js +19 -22
- package/src/parts/CrossOriginEmbedderPolicy/CrossOriginEmbedderPolicy.js +1 -1
- package/src/parts/CrossOriginOpenerPolicy/CrossOriginOpenerPolicy.js +2 -2
- package/src/parts/Debug/Debug.js +2 -3
- package/src/parts/DefaultUrl/DefaultUrl.js +3 -4
- package/src/parts/Desktop/Desktop.js +18 -19
- package/src/parts/DesktopCapturer/DesktopCapturer.ipc.js +4 -6
- package/src/parts/DesktopCapturer/DesktopCapturer.js +3 -4
- package/src/parts/DesktopType/DesktopType.js +3 -3
- package/src/parts/DestroySocket/DestroySocket.js +5 -4
- package/src/parts/Developer/Developer.ipc.js +12 -14
- package/src/parts/Developer/Developer.js +33 -40
- package/src/parts/DirentType/DirentType.js +12 -12
- package/src/parts/Download/Download.ipc.js +4 -6
- package/src/parts/Download/Download.js +20 -19
- package/src/parts/DownloadAndExtract/DownloadAndExtract.js +16 -20
- package/src/parts/ElectronApplicationMenu/ElectronApplicationMenu.ipc.js +5 -7
- package/src/parts/ElectronApplicationMenu/ElectronApplicationMenu.js +20 -23
- package/src/parts/ElectronBrowserView/ElectronBrowserView.ipc.js +5 -7
- package/src/parts/ElectronBrowserView/ElectronBrowserView.js +18 -21
- package/src/parts/ElectronBrowserViewFunctions/ElectronBrowserViewFunctions.ipc.js +17 -19
- package/src/parts/ElectronBrowserViewFunctions/ElectronBrowserViewFunctions.js +26 -41
- package/src/parts/ElectronBrowserViewIpcState/ElectronBrowserViewIpcState.js +10 -14
- package/src/parts/ElectronBrowserViewQuickPick/ElectronBrowserViewQuickPick.ipc.js +5 -7
- package/src/parts/ElectronBrowserViewQuickPick/ElectronBrowserViewQuickPick.js +5 -7
- package/src/parts/ElectronBrowserViewState/ElectronBrowserViewState.js +8 -11
- package/src/parts/ElectronBrowserViewSuggestions/ElectronBrowserViewSuggestions.ipc.js +6 -8
- package/src/parts/ElectronBrowserViewSuggestions/ElectronBrowserViewSuggestions.js +7 -10
- package/src/parts/ElectronClipBoard/ElectronClipBoard.ipc.js +4 -6
- package/src/parts/ElectronClipBoard/ElectronClipBoard.js +3 -4
- package/src/parts/ElectronContentTracing/ElectronContentTracing.ipc.js +5 -7
- package/src/parts/ElectronContentTracing/ElectronContentTracing.js +5 -7
- package/src/parts/ElectronContextMenu/ElectronContextMenu.ipc.js +4 -6
- package/src/parts/ElectronContextMenu/ElectronContextMenu.js +7 -8
- package/src/parts/ElectronDeveloper/ElectronDeveloper.ipc.js +4 -6
- package/src/parts/ElectronDeveloper/ElectronDeveloper.js +3 -4
- package/src/parts/ElectronDialog/ElectronDialog.ipc.js +5 -7
- package/src/parts/ElectronDialog/ElectronDialog.js +5 -7
- package/src/parts/ElectronInitialize/ElectronInitialize.ipc.js +4 -6
- package/src/parts/ElectronInitialize/ElectronInitialize.js +9 -10
- package/src/parts/ElectronNet/ElectronNet.ipc.js +4 -6
- package/src/parts/ElectronNet/ElectronNet.js +3 -4
- package/src/parts/ElectronNetLog/ElectronNetLog.ipc.js +5 -7
- package/src/parts/ElectronNetLog/ElectronNetLog.js +5 -7
- package/src/parts/ElectronPowerSaveBlocker/ElectronPowerSaveBlocker.ipc.js +5 -7
- package/src/parts/ElectronPowerSaveBlocker/ElectronPowerSaveBlocker.js +5 -7
- package/src/parts/ElectronProcess/ElectronProcess.ipc.js +5 -7
- package/src/parts/ElectronProcess/ElectronProcess.js +5 -7
- package/src/parts/ElectronSafeStorage/ElectronSafeStorage.ipc.js +6 -8
- package/src/parts/ElectronSafeStorage/ElectronSafeStorage.js +10 -13
- package/src/parts/ElectronShell/ElectronShell.ipc.js +4 -6
- package/src/parts/ElectronShell/ElectronShell.js +3 -4
- package/src/parts/ElectronWebContents/ElectronWebContents.ipc.js +11 -13
- package/src/parts/ElectronWebContents/ElectronWebContents.js +45 -61
- package/src/parts/ElectronWebContentsView/ElectronWebContentsView.ipc.js +5 -7
- package/src/parts/ElectronWebContentsView/ElectronWebContentsView.js +16 -18
- package/src/parts/ElectronWebContentsViewFunctions/ElectronWebContentsViewFunctions.ipc.js +17 -19
- package/src/parts/ElectronWebContentsViewFunctions/ElectronWebContentsViewFunctions.js +26 -41
- package/src/parts/ElectronWindow/ElectronWindow.ipc.js +15 -17
- package/src/parts/ElectronWindow/ElectronWindow.js +60 -81
- package/src/parts/ElectronWindowAbout/ElectronWindowAbout.ipc.js +4 -6
- package/src/parts/ElectronWindowAbout/ElectronWindowAbout.js +3 -4
- package/src/parts/ElectronWindowProcessExplorer/ElectronWindowProcessExplorer.ipc.js +4 -6
- package/src/parts/ElectronWindowProcessExplorer/ElectronWindowProcessExplorer.js +31 -33
- package/src/parts/EncodingType/EncodingType.js +2 -2
- package/src/parts/Env/Env.js +11 -16
- package/src/parts/Error/FileSystemError.js +6 -7
- package/src/parts/ErrorCodes/ErrorCodes.js +22 -22
- package/src/parts/ErrorHandling/ErrorHandling.js +52 -60
- package/src/parts/Exec/Exec.js +11 -12
- package/src/parts/ExecCommand/ExecCommand.js +19 -22
- package/src/parts/ExecPromise/ExecPromise.js +3 -4
- package/src/parts/Exit/Exit.ipc.js +4 -6
- package/src/parts/Exit/Exit.js +3 -4
- package/src/parts/ExitCode/ExitCode.js +3 -5
- package/src/parts/ExportStatic/ExportStatic.js +318 -419
- package/src/parts/ExtensionHostHelperProcessIpc/ExtensionHostHelperProcessIpc.js +13 -14
- package/src/parts/ExtensionHostRpc/ExtensionHostRpc.js +70 -79
- package/src/parts/ExtensionInstall/ExtensionInstall.ipc.js +4 -6
- package/src/parts/ExtensionInstall/ExtensionInstall.js +21 -23
- package/src/parts/ExtensionInstallFromFile/ExtensionInstallFromFile.js +32 -33
- package/src/parts/ExtensionInstallFromGitHub/ExtensionInstallFromGitHub.js +30 -30
- package/src/parts/ExtensionInstallFromUrl/ExtensionInstallFromUrl.js +30 -30
- package/src/parts/ExtensionInstallParseInput/ExtensionInstallParseInput.js +43 -46
- package/src/parts/ExtensionInstallType/ExtensionInstallType.js +4 -7
- package/src/parts/ExtensionLink/ExtensionLink.js +40 -40
- package/src/parts/ExtensionList/ExtensionList.js +57 -63
- package/src/parts/ExtensionManagement/ExtensionManagement.ipc.js +16 -17
- package/src/parts/ExtensionManagement/ExtensionManagement.js +70 -87
- package/src/parts/ExtensionManagement/ExtensionManagementColorTheme.js +62 -70
- package/src/parts/ExtensionManagement/ExtensionManagementIconTheme.js +26 -26
- package/src/parts/ExtensionManagement/ExtensionManagementLanguages.js +55 -59
- package/src/parts/ExtensionManifest/ExtensionManifest.js +50 -48
- package/src/parts/ExtensionManifestInputType/ExtensionManifestInputType.js +3 -5
- package/src/parts/ExtensionManifestStatus/ExtensionManifestStatus.js +2 -3
- package/src/parts/ExtensionManifests/ExtensionManifests.js +36 -40
- package/src/parts/ExtensionManifests/ExtensionManifestsFromFolder.js +19 -19
- package/src/parts/ExtensionManifests/ExtensionManifestsFromLinkedExtensionsFolder.js +46 -47
- package/src/parts/ExtensionManifests/ExtensionManifestsFromOnlyExtension.js +7 -8
- package/src/parts/ExtensionUninstall/ExtensionUninstall.js +17 -17
- package/src/parts/ExtensionUnlink/ExtensionUnlink.js +19 -19
- package/src/parts/Extract/Extract.js +24 -28
- package/src/parts/FileNotFoundError/FileNotFoundError.js +11 -13
- package/src/parts/FileSystem/FileSystem.ipc.js +27 -30
- package/src/parts/FileSystem/FileSystem.js +214 -228
- package/src/parts/FileSystemWatch/FileSystemWatch.js +4 -5
- package/src/parts/FirstNodeWorkerEventType/FirstNodeWorkerEventType.js +3 -3
- package/src/parts/GetAccurateMemoryUsage/GetAccurateMemoryUsage.js +34 -34
- package/src/parts/GetAppImageDownloadUrl/GetAppImageDownloadUrl.js +4 -5
- package/src/parts/GetAppImagePath/GetAppImagePath.js +3 -4
- package/src/parts/GetAppWindowOptions/GetAppWindowOptions.js +26 -28
- package/src/parts/GetBrowserWindowOptions/GetBrowserWindowOptions.js +26 -27
- package/src/parts/GetContentSecurityPolicy/GetContentSecurityPolicy.js +4 -5
- package/src/parts/GetDirentType/GetDirentType.js +24 -25
- package/src/parts/GetElectronFileResponse/GetElectronFileResponse.ipc.js +4 -6
- package/src/parts/GetElectronFileResponse/GetElectronFileResponse.js +43 -43
- package/src/parts/GetElectronFileResponseAbsolutePath/GetElectronFileResponseAbsolutePath.js +32 -33
- package/src/parts/GetElectronFileResponseContent/GetElectronFileResponseContent.js +15 -16
- package/src/parts/GetElectronFileResponseRelativePath/GetElectronFileResponseRelativePath.js +11 -13
- package/src/parts/GetElectronRebuildPath/GetElectronRebuildPath.js +8 -9
- package/src/parts/GetEtag/GetEtag.js +2 -2
- package/src/parts/GetFirstEvent/GetFirstEvent.js +20 -21
- package/src/parts/GetFirstNodeWorkerEvent/GetFirstNodeWorkerEvent.js +7 -8
- package/src/parts/GetFirstSpawnedProcessEvent/GetFirstSpawnedProcessEvent.js +7 -8
- package/src/parts/GetHeaders/GetHeaders.js +50 -52
- package/src/parts/GetHeadersDefault/GetHeadersDefault.js +2 -2
- package/src/parts/GetHeadersExtensionHostWorker/GetHeadersExtensionHostWorker.js +8 -9
- package/src/parts/GetHeadersMainFrame/GetHeadersMainFrame.js +10 -11
- package/src/parts/GetHeadersOtherWorker/GetHeadersOtherWorker.js +12 -13
- package/src/parts/GetHeadersRendererWorker/GetHeadersRendererWorker.js +8 -9
- package/src/parts/GetHeadersSyntaxHighlightingWorker/GetHeadersSyntaxHighlightingWorker.js +8 -9
- package/src/parts/GetHeadersTerminalWorker/GetHeadersTerminalWorker.js +8 -9
- package/src/parts/GetHeadersTestWorker/GetHeadersTestWorker.js +8 -9
- package/src/parts/GetHelpString/GetHelpString.js +4 -5
- package/src/parts/GetHttpErrorMessage/GetHttpErrorMessage.js +20 -21
- package/src/parts/GetIcon/GetIcon.js +17 -18
- package/src/parts/GetLatestReleaseVersion/GetLatestReleaseVersion.js +29 -30
- package/src/parts/GetMimeType/GetMimeType.js +26 -27
- package/src/parts/GetNewLineIndex/GetNewLineIndex.js +3 -4
- package/src/parts/GetNotFoundResponse/GetNotFoundResponse.js +10 -11
- package/src/parts/GetNotModifiedResponse/GetNotModifiedResponse.js +9 -10
- package/src/parts/GetNsisUpdateArgs/GetNsisUpdateArgs.js +6 -6
- package/src/parts/GetNsisUpdateDownloadPath/GetNsisUpdateDownloadPath.js +9 -10
- package/src/parts/GetPathName/GetPathName.js +3 -3
- package/src/parts/GetPreloadUrl/GetPreloadUrl.js +4 -5
- package/src/parts/GetProcessExplorerUrl/GetProcessExplorerUrl.js +3 -4
- package/src/parts/GetPsOutput/GetPsOutput.js +16 -17
- package/src/parts/GetRemoteUrl/GetRemoteUrl.js +4 -5
- package/src/parts/GetServerErrorResponse/GetServerErrorResponse.js +10 -11
- package/src/parts/GetStatusString/GetStatusString.js +54 -62
- package/src/parts/GetTerminalProcessPath/GetTerminalProcessPath.js +4 -5
- package/src/parts/GetTerminalSpawnOptions/GetTerminalSpawnOptions.ipc.js +4 -6
- package/src/parts/GetTerminalSpawnOptions/GetTerminalSpawnOptions.js +16 -17
- package/src/parts/GetTestPath/GetTestPath.js +10 -11
- package/src/parts/GetTestRequestResponse/GetTestRequestResponse.js +41 -42
- package/src/parts/GetTitleBarItems/GetTitleBarItems.js +40 -41
- package/src/parts/GetTypeFromUrl/GetTypeFromUrl.js +17 -18
- package/src/parts/GetTypeScriptPath/GetTypeScriptPath.js +11 -20
- package/src/parts/GetVersionString/GetVersionString.js +4 -5
- package/src/parts/GetWindowId/GetWindowId.ipc.js +4 -6
- package/src/parts/GetWindowId/GetWindowId.js +4 -5
- package/src/parts/GetWindowsNsisDownloadUrl/GetWindowsNsisDownloadUrl.js +6 -7
- package/src/parts/GetWorkspaceId/GetWorkspaceId.js +3 -4
- package/src/parts/GitLsFiles/GitLsFiles.ipc.js +6 -8
- package/src/parts/GitLsFiles/GitLsFiles.js +19 -22
- package/src/parts/HandleCliArgs/HandleCliArgs.ipc.js +4 -6
- package/src/parts/HandleCliArgs/HandleCliArgs.js +11 -11
- package/src/parts/HandleElectronMessagePort/HandleElectronMessagePort.ipc.js +4 -6
- package/src/parts/HandleElectronMessagePort/HandleElectronMessagePort.js +14 -14
- package/src/parts/HandleElectronReady/HandleElectronReady.ipc.js +4 -6
- package/src/parts/HandleElectronReady/HandleElectronReady.js +8 -9
- package/src/parts/HandleIpc/HandleIpc.js +20 -23
- package/src/parts/HandleMessagePortForExtensionHostHelperProcess/HandleMessagePortForExtensionHostHelperProcess.ipc.js +4 -6
- package/src/parts/HandleMessagePortForExtensionHostHelperProcess/HandleMessagePortForExtensionHostHelperProcess.js +17 -18
- package/src/parts/HandleMessagePortForTerminalProcess/HandleMessagePortForTerminalProcess.ipc.js +4 -6
- package/src/parts/HandleMessagePortForTerminalProcess/HandleMessagePortForTerminalProcess.js +8 -9
- package/src/parts/HandleNodeMessagePort/HandleNodeMessagePort.ipc.js +4 -6
- package/src/parts/HandleNodeMessagePort/HandleNodeMessagePort.js +9 -10
- package/src/parts/HandleRemoteRequest/HandleRemoteRequest.ipc.js +4 -6
- package/src/parts/HandleRemoteRequest/HandleRemoteRequest.js +8 -9
- package/src/parts/HandleRequestTest/HandleRequestTest.ipc.js +4 -6
- package/src/parts/HandleRequestTest/HandleRequestTest.js +9 -10
- package/src/parts/HandleSocketError/HandleSocketError.js +10 -11
- package/src/parts/HandleUncaughtExceptionMonitor/HandleUncaughtExceptionMonitor.js +9 -12
- package/src/parts/HandleWebSocket/HandleWebSocket.ipc.js +4 -6
- package/src/parts/HandleWebSocket/HandleWebSocket.js +19 -19
- package/src/parts/HandleWebSocketForExtensionHostHelperProcess/HandleWebSocketForExtensionHostHelperProcess.js +8 -9
- package/src/parts/HandleWebSocketForSharedProcess/HandleWebSocketForSharedProcess.js +15 -16
- package/src/parts/HandleWebSocketForTerminalProcess/HandleWebSocketForTerminalProcess.js +17 -21
- package/src/parts/HandleWebSocketForUnknown/HandleWebSocketForUnknown.js +9 -9
- package/src/parts/HandleWebSocketModule/HandleWebSocketModule.js +16 -17
- package/src/parts/HandleWindowAllClosed/HandleWindowAllClosed.ipc.js +4 -6
- package/src/parts/HandleWindowAllClosed/HandleWindowAllClosed.js +9 -10
- package/src/parts/HasPositiveMemoryUsage/HasPositiveMemoryUsage.js +2 -2
- package/src/parts/Hash/Hash.js +4 -6
- package/src/parts/HeapSnapshot/HeapSnapshot.ipc.js +4 -6
- package/src/parts/HeapSnapshot/HeapSnapshot.js +6 -9
- package/src/parts/HttpHeader/HttpHeader.js +7 -7
- package/src/parts/HttpServerResponse/HttpServerResponse.js +15 -16
- package/src/parts/HttpStatusCode/HttpStatusCode.js +5 -5
- package/src/parts/Id/Id.js +4 -5
- package/src/parts/IncrementalTextSearch/IncrementalTextSearch.js +44 -47
- package/src/parts/IncrementalTextSearch/IncremetalTextSearch.ipc.js +4 -6
- package/src/parts/InferExtensionId/InferExtensionId.js +7 -8
- package/src/parts/InstallExtension/InstallExtension.ipc.js +3 -4
- package/src/parts/InstallExtension/InstallExtension.js +32 -32
- package/src/parts/IpcChild/IpcChild.js +12 -13
- package/src/parts/IpcChildModule/IpcChildModule.js +19 -26
- package/src/parts/IpcChildType/IpcChildType.js +18 -19
- package/src/parts/IpcChildWithElectronMessagePort/IpcChildWithElectronMessagePort.js +47 -48
- package/src/parts/IpcChildWithNodeMessagePort/IpcChildWithNodeMessagePort.js +44 -41
- package/src/parts/IpcError/IpcError.js +4 -4
- package/src/parts/IpcParent/IpcParent.js +8 -9
- package/src/parts/IpcParentModule/IpcParentModule.js +13 -14
- package/src/parts/IpcParentType/IpcParentType.js +3 -3
- package/src/parts/IpcParentWithElectronUtilityProcess/IpcParentWithElectronUtilityProcess.js +49 -48
- package/src/parts/IsAbsolutePath/IsAbsolutePath.js +3 -4
- package/src/parts/IsAppImage/IsAppImage.js +3 -4
- package/src/parts/IsAutoUpdateSupported/IsAutoUpdateSupported.ipc.js +4 -6
- package/src/parts/IsAutoUpdateSupported/IsAutoUpdateSupported.js +6 -8
- package/src/parts/IsBuiltServer/IsBuiltServer.js +1 -1
- package/src/parts/IsDlOpenError/IsDlOpenError.js +3 -4
- package/src/parts/IsElectron/IsElectron.js +3 -4
- package/src/parts/IsEnoentError/IsEnoentError.js +9 -11
- package/src/parts/IsEnoentErrorWindows/IsEnoentErrorWindows.js +2 -2
- package/src/parts/IsEsrchError/IsEsrchError.js +3 -4
- package/src/parts/IsIgnoredError/IsIgnoredError.js +12 -13
- package/src/parts/IsMessagePort/IsMessagePort.js +2 -2
- package/src/parts/IsMessagePortMain/IsMessagePortMain.js +2 -2
- package/src/parts/IsTypeScriptPath/IsTypeScriptPath.js +2 -2
- package/src/parts/IsWindows/IsWindows.js +1 -1
- package/src/parts/JoinLines/JoinLines.js +3 -4
- package/src/parts/Json/Json.js +15 -17
- package/src/parts/JsonFile/JsonFile.js +10 -12
- package/src/parts/JsonRpc/JsonRpc.js +1 -1
- package/src/parts/JsonRpcVersion/JsonRpcVersion.js +1 -1
- package/src/parts/Jsonc/Jsonc.js +1 -1
- package/src/parts/JsoncFile/JsoncFile.js +7 -8
- package/src/parts/LeftCut/LeftCut.js +17 -18
- package/src/parts/LimitString/LimitString.js +13 -14
- package/src/parts/ListProcessGetName/ListProcessGetName.js +55 -56
- package/src/parts/ListProcessesWithMemoryUsage/ListProcessesWithMemoryUsage.ipc.js +4 -6
- package/src/parts/ListProcessesWithMemoryUsage/ListProcessesWithMemoryUsage.js +9 -11
- package/src/parts/ListProcessesWithMemoryUsageUnix/ListProcessesWithMemoryUsageUnix.js +19 -20
- package/src/parts/ListProcessesWithMemoryUsageWindows/ListProcessesWithMemoryUsageWindows.js +33 -36
- package/src/parts/LoadTypeScript/LoadTypeScript.js +12 -12
- package/src/parts/LoadWindowsProcessTree/LoadWindowsProcessTree.js +11 -13
- package/src/parts/Logger/Logger.js +34 -42
- package/src/parts/Main/Main.js +13 -14
- package/src/parts/MakeExecutable/MakeExecutable.js +9 -9
- package/src/parts/MimeType/MimeType.js +37 -37
- package/src/parts/Module/Module.js +150 -151
- package/src/parts/ModuleId/ModuleId.js +76 -76
- package/src/parts/ModuleMap/ModuleMap.js +329 -330
- package/src/parts/OpenExternal/OpenExternal.ipc.js +5 -7
- package/src/parts/OpenExternal/OpenExternal.js +5 -7
- package/src/parts/OpenNativeFolder/OpenNativeFolder.ipc.js +4 -6
- package/src/parts/OpenNativeFolder/OpenNativeFolder.js +9 -9
- package/src/parts/Os/Os.ipc.js +4 -6
- package/src/parts/Os/Os.js +3 -4
- package/src/parts/OutputChannel/OutputChannel.ipc.js +35 -39
- package/src/parts/OutputChannel/OutputChannel.js +32 -35
- package/src/parts/OutputChannelState/OutputChannelState.js +10 -14
- package/src/parts/ParentIpc/ParentIpc.js +19 -25
- package/src/parts/ParseInt/ParseInt.js +2 -2
- package/src/parts/ParseMemory/ParseMemory.js +9 -10
- package/src/parts/ParsePsOutput/ParsePsOutput.js +42 -46
- package/src/parts/ParseRipGrepLines/ParseRipGrepLines.js +9 -10
- package/src/parts/ParseUrlGithub/ParseUrlGithub.js +49 -51
- package/src/parts/Path/Path.js +11 -16
- package/src/parts/Performance/Performance.ipc.js +4 -6
- package/src/parts/Performance/Performance.js +16 -27
- package/src/parts/Platform/Platform.ipc.js +28 -30
- package/src/parts/Platform/Platform.js +46 -73
- package/src/parts/PlatformPaths/PlatformPaths.ipc.js +21 -23
- package/src/parts/PlatformPaths/PlatformPaths.js +79 -114
- package/src/parts/Preferences/Preferences.ipc.js +4 -6
- package/src/parts/Preferences/Preferences.js +69 -70
- package/src/parts/PrettyError/PrettyError.js +1 -1
- package/src/parts/PrintPrettyError/PrintPrettyError.js +3 -4
- package/src/parts/Process/Process.ipc.js +10 -12
- package/src/parts/Process/Process.js +35 -48
- package/src/parts/ProcessDisplayName/ProcessDisplayName.js +1 -1
- package/src/parts/ProcessExitEventType/ProcessExitEventType.js +2 -2
- package/src/parts/ProcessId/ProcessId.ipc.js +5 -7
- package/src/parts/ProcessId/ProcessId.js +4 -5
- package/src/parts/ProcessListeners/ProcessListeners.js +11 -14
- package/src/parts/Promises/Promises.js +18 -18
- package/src/parts/ProtocolType/ProtocolType.js +4 -4
- package/src/parts/PtyHost/PtyHost.js +56 -62
- package/src/parts/PtyHostPath/PtyHostPath.js +10 -10
- package/src/parts/PtyHostState/PtyHostState.js +16 -16
- package/src/parts/Queue/Queue.js +30 -31
- package/src/parts/RebuildForElectron/RebuildForElectron.js +14 -14
- package/src/parts/RebuildForNode/RebuildForNode.js +12 -12
- package/src/parts/RebuildNodePty/RebuildNodePty.ipc.js +4 -6
- package/src/parts/RebuildNodePty/RebuildNodePty.js +20 -22
- package/src/parts/RecentlyOpened/RecentlyOpened.ipc.js +4 -6
- package/src/parts/RecentlyOpened/RecentlyOpened.js +54 -53
- package/src/parts/RemoveSymlink/RemoveSymlink.js +11 -11
- package/src/parts/RequiresSocket/RequiresSocket.js +14 -15
- package/src/parts/Restart/Restart.js +9 -10
- package/src/parts/RipGrep/RipGrep.js +35 -37
- package/src/parts/RipGrepParsedLineType/RipGrepParsedLineType.js +4 -4
- package/src/parts/RipGrepPath/RipGrepPath.js +1 -1
- package/src/parts/Root/Root.js +4 -6
- package/src/parts/Screen/Screen.ipc.js +6 -8
- package/src/parts/Screen/Screen.js +7 -10
- package/src/parts/SearchFile/SearchFile.ipc.js +4 -6
- package/src/parts/SearchFile/SearchFile.js +26 -27
- package/src/parts/SetHeaders/SetHeaders.js +4 -4
- package/src/parts/ShouldLogError/ShouldLogError.js +6 -7
- package/src/parts/ShouldTranspileTypescript/ShouldTranspileTypescript.js +10 -11
- package/src/parts/Signal/Signal.js +3 -3
- package/src/parts/SplitLines/SplitLines.js +3 -4
- package/src/parts/SymLink/SymLink.js +3 -4
- package/src/parts/TemporaryMessagePort/TemporaryMessagePort.ipc.js +4 -6
- package/src/parts/TemporaryMessagePort/TemporaryMessagePort.js +18 -21
- package/src/parts/Terminal/Terminal.ipc.js +7 -9
- package/src/parts/Terminal/Terminal.js +68 -73
- package/src/parts/TerminalState/TerminalState.js +8 -11
- package/src/parts/TextDocument/TextDocument.ipc.js +3 -4
- package/src/parts/TextDocument/TextDocument.js +17 -22
- package/src/parts/TextSearch/TextSearch.ipc.js +4 -6
- package/src/parts/TextSearch/TextSearch.js +18 -22
- package/src/parts/TextSearchError/TextSearchError.js +12 -12
- package/src/parts/TextSearchResultType/TextSearchResultType.js +2 -2
- package/src/parts/Timeout/Timeout.js +4 -5
- package/src/parts/TmpFile/TmpFile.js +11 -13
- package/src/parts/ToAbsolutePaths/ToAbsolutePaths.js +7 -8
- package/src/parts/ToTextSearchResult/ToTextSearchResult.js +23 -24
- package/src/parts/Trace/Trace.js +10 -14
- package/src/parts/TranspileTypeScript/TranspileTypeScript.js +19 -19
- package/src/parts/Trash/Trash.js +15 -16
- package/src/parts/TrashElectron/TrashElectron.js +7 -8
- package/src/parts/TrashNode/TrashNode.js +3 -4
- package/src/parts/UpdateState/UpdateState.js +7 -10
- package/src/parts/UpdateStateType/UpdateStateType.js +9 -9
- package/src/parts/VError/VError.js +1 -1
- package/src/parts/WaitForProcessToExit/WaitForProcessToExit.js +7 -8
- package/src/parts/WebSocketServer/WebSocketServer.ipc.js +4 -6
- package/src/parts/WebSocketServer/WebSocketServer.js +1 -1
- package/src/parts/WindowsProcessTree/WindowsProcessTree.js +12 -14
- package/src/parts/WindowsProcessTreeDataFlag/WindowsProcessTreeDataFlag.js +3 -3
- package/src/parts/Workspace/Workspace.ipc.js +5 -7
- package/src/parts/Workspace/Workspace.js +79 -84
- package/src/parts/WorkspaceSource/WorkspaceSource.js +2 -2
- package/src/sharedProcessMain.js +2 -3
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import * as ElectronShell from './ElectronShell.js'
|
|
2
|
-
|
|
3
|
-
export const name = 'ElectronShell'
|
|
4
|
-
|
|
1
|
+
import * as ElectronShell from './ElectronShell.js';
|
|
2
|
+
export const name = 'ElectronShell';
|
|
5
3
|
export const Commands = {
|
|
6
|
-
|
|
7
|
-
}
|
|
4
|
+
beep: ElectronShell.beep,
|
|
5
|
+
};
|
|
@@ -1,14 +1,12 @@
|
|
|
1
|
-
import * as ElectronWebContents from './ElectronWebContents.js'
|
|
2
|
-
|
|
3
|
-
export const name = 'ElectronWebContents'
|
|
4
|
-
|
|
1
|
+
import * as ElectronWebContents from './ElectronWebContents.js';
|
|
2
|
+
export const name = 'ElectronWebContents';
|
|
5
3
|
export const Commands = {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
}
|
|
4
|
+
dispose: ElectronWebContents.dispose,
|
|
5
|
+
handleKeyBinding: ElectronWebContents.handleKeyBinding,
|
|
6
|
+
handleWindowOpen: ElectronWebContents.handleWindowOpen,
|
|
7
|
+
handleWillNavigate: ElectronWebContents.handleWillNavigate,
|
|
8
|
+
handleDidNavigate: ElectronWebContents.handleDidNavigate,
|
|
9
|
+
handleContextMenu: ElectronWebContents.handleContextMenu,
|
|
10
|
+
handleTitleUpdated: ElectronWebContents.handleTitleUpdated,
|
|
11
|
+
handleBrowserViewDestroyed: ElectronWebContents.handleBrowserViewDestroyed, // TODO rename to webcontents
|
|
12
|
+
};
|
|
@@ -1,77 +1,61 @@
|
|
|
1
|
-
import * as ElectronBrowserViewIpcState from '../ElectronBrowserViewIpcState/ElectronBrowserViewIpcState.js'
|
|
2
|
-
import * as ElectronBrowserViewState from '../ElectronBrowserViewState/ElectronBrowserViewState.js'
|
|
3
|
-
import * as ParentIpc from '../ParentIpc/ParentIpc.js'
|
|
4
|
-
|
|
1
|
+
import * as ElectronBrowserViewIpcState from '../ElectronBrowserViewIpcState/ElectronBrowserViewIpcState.js';
|
|
2
|
+
import * as ElectronBrowserViewState from '../ElectronBrowserViewState/ElectronBrowserViewState.js';
|
|
3
|
+
import * as ParentIpc from '../ParentIpc/ParentIpc.js';
|
|
5
4
|
export const dispose = async (id) => {
|
|
6
|
-
|
|
7
|
-
}
|
|
8
|
-
|
|
5
|
+
await ParentIpc.invoke('ElectronWebContents.dispose', id);
|
|
6
|
+
};
|
|
9
7
|
export const callFunction = (webContentsId, method, ...params) => {
|
|
10
|
-
|
|
11
|
-
}
|
|
12
|
-
|
|
8
|
+
return ParentIpc.invoke(`ElectronWebContents.callFunction`, webContentsId, method, ...params);
|
|
9
|
+
};
|
|
13
10
|
export const focus = (webContentsId) => {
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
11
|
+
return callFunction(webContentsId, 'focus');
|
|
12
|
+
};
|
|
17
13
|
export const openDevtools = (webContentsId) => {
|
|
18
|
-
|
|
19
|
-
}
|
|
20
|
-
|
|
14
|
+
return callFunction(webContentsId, 'openDevTools');
|
|
15
|
+
};
|
|
21
16
|
export const reload = (webContentsId) => {
|
|
22
|
-
|
|
23
|
-
}
|
|
24
|
-
|
|
17
|
+
return callFunction(webContentsId, 'reload');
|
|
18
|
+
};
|
|
25
19
|
export const forward = (webContentsId) => {
|
|
26
|
-
|
|
27
|
-
}
|
|
28
|
-
|
|
20
|
+
return callFunction(webContentsId, 'goForward');
|
|
21
|
+
};
|
|
29
22
|
export const backward = (webContentsId) => {
|
|
30
|
-
|
|
31
|
-
}
|
|
32
|
-
|
|
23
|
+
return callFunction(webContentsId, 'goBack');
|
|
24
|
+
};
|
|
33
25
|
export const inspectElement = (webContentsId, x, y) => {
|
|
34
|
-
|
|
35
|
-
}
|
|
36
|
-
|
|
26
|
+
return callFunction(webContentsId, `inspectElement`, x, y);
|
|
27
|
+
};
|
|
37
28
|
export const handleWindowOpen = (webContentsId, url) => {
|
|
38
|
-
|
|
39
|
-
}
|
|
40
|
-
|
|
29
|
+
// TODO
|
|
30
|
+
};
|
|
41
31
|
const forwardEvent = (method, webContentsId, ...params) => {
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
}
|
|
53
|
-
|
|
32
|
+
const ipc = ElectronBrowserViewIpcState.get(webContentsId);
|
|
33
|
+
if (!ipc) {
|
|
34
|
+
console.log(`[shared-process] no ipc for webcontents ${webContentsId}`);
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
ipc.send({
|
|
38
|
+
jsonrpc: '2.0',
|
|
39
|
+
method: `SimpleBrowser.${method}`,
|
|
40
|
+
params,
|
|
41
|
+
});
|
|
42
|
+
};
|
|
54
43
|
export const handleWillNavigate = (...args) => {
|
|
55
|
-
|
|
56
|
-
}
|
|
57
|
-
|
|
44
|
+
return forwardEvent('handleWillNavigate', ...args);
|
|
45
|
+
};
|
|
58
46
|
export const handleDidNavigate = (...args) => {
|
|
59
|
-
|
|
60
|
-
}
|
|
61
|
-
|
|
47
|
+
return forwardEvent('handleDidNavigate', ...args);
|
|
48
|
+
};
|
|
62
49
|
export const handleContextMenu = (...args) => {
|
|
63
|
-
|
|
64
|
-
}
|
|
65
|
-
|
|
50
|
+
return forwardEvent('handleContextMenu', ...args);
|
|
51
|
+
};
|
|
66
52
|
export const handleTitleUpdated = (...args) => {
|
|
67
|
-
|
|
68
|
-
}
|
|
69
|
-
|
|
53
|
+
return forwardEvent('handleTitleUpdated', ...args);
|
|
54
|
+
};
|
|
70
55
|
export const handleKeyBinding = (...args) => {
|
|
71
|
-
|
|
72
|
-
}
|
|
73
|
-
|
|
56
|
+
forwardEvent('handleKeyBinding', ...args);
|
|
57
|
+
};
|
|
74
58
|
export const handleBrowserViewDestroyed = (id) => {
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
}
|
|
59
|
+
ElectronBrowserViewState.remove(id);
|
|
60
|
+
ElectronBrowserViewIpcState.remove(id);
|
|
61
|
+
};
|
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
import * as ElectronWebContentsView from './ElectronWebContentsView.js'
|
|
2
|
-
|
|
3
|
-
export const name = 'ElectronWebContentsView'
|
|
4
|
-
|
|
1
|
+
import * as ElectronWebContentsView from './ElectronWebContentsView.js';
|
|
2
|
+
export const name = 'ElectronWebContentsView';
|
|
5
3
|
export const Commands = {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
}
|
|
4
|
+
createWebContentsView: ElectronWebContentsView.createWebContentsView,
|
|
5
|
+
disposeWebContentsView: ElectronWebContentsView.disposeWebContentsView,
|
|
6
|
+
};
|
|
@@ -1,20 +1,18 @@
|
|
|
1
|
-
import * as ElectronBrowserViewIpcState from '../ElectronBrowserViewIpcState/ElectronBrowserViewIpcState.js'
|
|
2
|
-
import * as ElectronWebContents from '../ElectronWebContents/ElectronWebContents.js'
|
|
3
|
-
import * as ParentIpc from '../ParentIpc/ParentIpc.js'
|
|
4
|
-
import * as Assert from '../Assert/Assert.js'
|
|
5
|
-
|
|
1
|
+
import * as ElectronBrowserViewIpcState from '../ElectronBrowserViewIpcState/ElectronBrowserViewIpcState.js';
|
|
2
|
+
import * as ElectronWebContents from '../ElectronWebContents/ElectronWebContents.js';
|
|
3
|
+
import * as ParentIpc from '../ParentIpc/ParentIpc.js';
|
|
4
|
+
import * as Assert from '../Assert/Assert.js';
|
|
6
5
|
export const createWebContentsView = async (ipc, restoreId, fallthroughKeyBindings) => {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
6
|
+
Assert.object(ipc);
|
|
7
|
+
Assert.number(restoreId);
|
|
8
|
+
const webContentsId = await ParentIpc.invoke('ElectronWebContentsView.createWebContentsView', restoreId);
|
|
9
|
+
ElectronBrowserViewIpcState.add(webContentsId, ipc);
|
|
10
|
+
// TODO get window id from renderer worker
|
|
11
|
+
await ParentIpc.invoke('ElectronWebContentsView.attachEventListeners', webContentsId);
|
|
12
|
+
await ParentIpc.invoke('ElectronWebContentsViewFunctions.setBackgroundColor', webContentsId, 'white');
|
|
13
|
+
return webContentsId;
|
|
14
|
+
};
|
|
17
15
|
export const disposeWebContentsView = async (id) => {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
}
|
|
16
|
+
await ParentIpc.invoke('ElectronWebContentsView.disposeWebContentsView', id);
|
|
17
|
+
await ElectronWebContents.dispose(id);
|
|
18
|
+
};
|
|
@@ -1,20 +1,18 @@
|
|
|
1
|
-
import * as ElectronWebContentsViewFunctions from './ElectronWebContentsViewFunctions.js'
|
|
2
|
-
|
|
3
|
-
export const name = 'ElectronWebContentsViewFunctions'
|
|
4
|
-
|
|
1
|
+
import * as ElectronWebContentsViewFunctions from './ElectronWebContentsViewFunctions.js';
|
|
2
|
+
export const name = 'ElectronWebContentsViewFunctions';
|
|
5
3
|
export const Commands = {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
}
|
|
4
|
+
resizeBrowserView: ElectronWebContentsViewFunctions.resizeBrowserView,
|
|
5
|
+
setIframeSrc: ElectronWebContentsViewFunctions.setIframeSrc,
|
|
6
|
+
focus: ElectronWebContentsViewFunctions.focus,
|
|
7
|
+
openDevtools: ElectronWebContentsViewFunctions.openDevtools,
|
|
8
|
+
reload: ElectronWebContentsViewFunctions.reload,
|
|
9
|
+
forward: ElectronWebContentsViewFunctions.forward,
|
|
10
|
+
backward: ElectronWebContentsViewFunctions.backward,
|
|
11
|
+
cancelNavigation: ElectronWebContentsViewFunctions.cancelNavigation,
|
|
12
|
+
show: ElectronWebContentsViewFunctions.show,
|
|
13
|
+
hide: ElectronWebContentsViewFunctions.hide,
|
|
14
|
+
inspectElement: ElectronWebContentsViewFunctions.inspectElement,
|
|
15
|
+
copyImageAt: ElectronWebContentsViewFunctions.copyImageAt,
|
|
16
|
+
setFallthroughKeyBindings: ElectronWebContentsViewFunctions.setFallthroughKeyBindings,
|
|
17
|
+
getStats: ElectronWebContentsViewFunctions.getStats,
|
|
18
|
+
};
|
|
@@ -1,50 +1,35 @@
|
|
|
1
|
-
import * as ParentIpc from '../ParentIpc/ParentIpc.js'
|
|
2
|
-
import * as ElectronWebContents from '../ElectronWebContents/ElectronWebContents.js'
|
|
3
|
-
|
|
1
|
+
import * as ParentIpc from '../ParentIpc/ParentIpc.js';
|
|
2
|
+
import * as ElectronWebContents from '../ElectronWebContents/ElectronWebContents.js';
|
|
4
3
|
export const resizeBrowserView = (id, x, y, width, height) => {
|
|
5
|
-
|
|
6
|
-
}
|
|
7
|
-
|
|
4
|
+
return ParentIpc.invoke('ElectronWebContentsViewFunctions.resizeBrowserView', id, x, y, width, height);
|
|
5
|
+
};
|
|
8
6
|
export const setIframeSrc = async (id, iframeSrc) => {
|
|
9
|
-
|
|
10
|
-
}
|
|
11
|
-
|
|
7
|
+
return ParentIpc.invoke('ElectronWebContentsViewFunctions.setIframeSrc', id, iframeSrc);
|
|
8
|
+
};
|
|
12
9
|
const callFunction = (id, functionName) => {
|
|
13
|
-
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export const
|
|
17
|
-
|
|
18
|
-
export const
|
|
19
|
-
|
|
20
|
-
export const reload = ElectronWebContents.reload
|
|
21
|
-
|
|
22
|
-
export const forward = ElectronWebContents.forward
|
|
23
|
-
|
|
24
|
-
export const backward = ElectronWebContents.backward
|
|
25
|
-
|
|
10
|
+
return ParentIpc.invoke('ElectronWebContents.callFunction', id, functionName);
|
|
11
|
+
};
|
|
12
|
+
export const focus = ElectronWebContents.focus;
|
|
13
|
+
export const openDevtools = ElectronWebContents.openDevtools;
|
|
14
|
+
export const reload = ElectronWebContents.reload;
|
|
15
|
+
export const forward = ElectronWebContents.forward;
|
|
16
|
+
export const backward = ElectronWebContents.backward;
|
|
26
17
|
export const cancelNavigation = (id) => {
|
|
27
|
-
|
|
28
|
-
}
|
|
29
|
-
|
|
18
|
+
return ParentIpc.invoke('ElectronWebContentsViewFunctions.cancelNavigation', id);
|
|
19
|
+
};
|
|
30
20
|
export const show = (id) => {
|
|
31
|
-
|
|
32
|
-
}
|
|
33
|
-
|
|
21
|
+
return ParentIpc.invoke('ElectronWebContentsViewFunctions.show', id);
|
|
22
|
+
};
|
|
34
23
|
export const hide = (id) => {
|
|
35
|
-
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
export const inspectElement = ElectronWebContents.inspectElement
|
|
39
|
-
|
|
24
|
+
return ParentIpc.invoke('ElectronWebContentsViewFunctions.hide', id);
|
|
25
|
+
};
|
|
26
|
+
export const inspectElement = ElectronWebContents.inspectElement;
|
|
40
27
|
export const copyImageAt = (id, x, y) => {
|
|
41
|
-
|
|
42
|
-
}
|
|
43
|
-
|
|
28
|
+
return ParentIpc.invoke('ElectronWebContentsViewFunctions.copyImageAt', id, x, y);
|
|
29
|
+
};
|
|
44
30
|
export const setFallthroughKeyBindings = (fallthroughKeyBindings) => {
|
|
45
|
-
|
|
46
|
-
}
|
|
47
|
-
|
|
31
|
+
return ParentIpc.invoke('ElectronWebContentsViewFunctions.setFallthroughKeyBindings', fallthroughKeyBindings);
|
|
32
|
+
};
|
|
48
33
|
export const getStats = (id) => {
|
|
49
|
-
|
|
50
|
-
}
|
|
34
|
+
return ParentIpc.invoke('ElectronWebContents.getStats', id);
|
|
35
|
+
};
|
|
@@ -1,18 +1,16 @@
|
|
|
1
|
-
import * as ElectronWindow from './ElectronWindow.js'
|
|
2
|
-
|
|
3
|
-
export const name = 'ElectronWindow'
|
|
4
|
-
|
|
1
|
+
import * as ElectronWindow from './ElectronWindow.js';
|
|
2
|
+
export const name = 'ElectronWindow';
|
|
5
3
|
export const Commands = {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
}
|
|
4
|
+
close: ElectronWindow.close,
|
|
5
|
+
focus: ElectronWindow.focus,
|
|
6
|
+
getZoom: ElectronWindow.getZoom,
|
|
7
|
+
maximize: ElectronWindow.maximize,
|
|
8
|
+
minimize: ElectronWindow.minimize,
|
|
9
|
+
openNew: ElectronWindow.openNew,
|
|
10
|
+
reload: ElectronWindow.reload,
|
|
11
|
+
toggleDevtools: ElectronWindow.toggleDevtools,
|
|
12
|
+
unmaximize: ElectronWindow.unmaximize,
|
|
13
|
+
zoomIn: ElectronWindow.zoomIn,
|
|
14
|
+
zoomOut: ElectronWindow.zoomOut,
|
|
15
|
+
zoomReset: ElectronWindow.zoomReset,
|
|
16
|
+
};
|
|
@@ -1,49 +1,40 @@
|
|
|
1
|
-
import * as AppWindow from '../AppWindow/AppWindow.js'
|
|
2
|
-
import * as Assert from '../Assert/Assert.js'
|
|
3
|
-
import * as Clamp from '../Clamp/Clamp.js'
|
|
4
|
-
import * as ParentIpc from '../ParentIpc/ParentIpc.js'
|
|
5
|
-
|
|
1
|
+
import * as AppWindow from '../AppWindow/AppWindow.js';
|
|
2
|
+
import * as Assert from '../Assert/Assert.js';
|
|
3
|
+
import * as Clamp from '../Clamp/Clamp.js';
|
|
4
|
+
import * as ParentIpc from '../ParentIpc/ParentIpc.js';
|
|
6
5
|
export const openNew = () => {
|
|
7
|
-
|
|
8
|
-
}
|
|
9
|
-
|
|
6
|
+
return AppWindow.openNew();
|
|
7
|
+
};
|
|
10
8
|
export const minimize = (windowId) => {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
|
|
9
|
+
Assert.number(windowId);
|
|
10
|
+
return ParentIpc.invoke('ElectronWindow.executeWindowFunction', windowId, 'minimize');
|
|
11
|
+
};
|
|
15
12
|
export const toggleDevtools = (windowId) => {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
}
|
|
19
|
-
|
|
13
|
+
Assert.number(windowId);
|
|
14
|
+
return ParentIpc.invoke('ElectronWindow.executeWebContentsFunction', windowId, 'toggleDevTools');
|
|
15
|
+
};
|
|
20
16
|
export const maximize = (windowId) => {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
}
|
|
24
|
-
|
|
17
|
+
Assert.number(windowId);
|
|
18
|
+
return ParentIpc.invoke('ElectronWindow.executeWindowFunction', windowId, 'maximize');
|
|
19
|
+
};
|
|
25
20
|
export const unmaximize = (windowId) => {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
}
|
|
29
|
-
|
|
21
|
+
Assert.number(windowId);
|
|
22
|
+
return ParentIpc.invoke('ElectronWindow.executeWindowFunction', windowId, 'unmaximize');
|
|
23
|
+
};
|
|
30
24
|
export const close = (windowId) => {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
}
|
|
34
|
-
|
|
25
|
+
Assert.number(windowId);
|
|
26
|
+
return ParentIpc.invoke('ElectronWindow.executeWindowFunction', windowId, 'close');
|
|
27
|
+
};
|
|
35
28
|
export const reload = (windowId) => {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
}
|
|
39
|
-
|
|
29
|
+
Assert.number(windowId);
|
|
30
|
+
return ParentIpc.invoke('ElectronWindow.executeWindowFunction', windowId, 'reload');
|
|
31
|
+
};
|
|
40
32
|
const setZoom = async (windowId, zoomFactor, minZoomLevel, maxZoomLevel) => {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
}
|
|
46
|
-
|
|
33
|
+
const newZoomFactor = Clamp.clamp(zoomFactor, minZoomLevel, maxZoomLevel);
|
|
34
|
+
await ParentIpc.invoke('ElectronWindow.executeWebContentsFunction', windowId, 'setZoomLevel', newZoomFactor);
|
|
35
|
+
// TODO
|
|
36
|
+
// await Preferences.update('window.zoomLevel', newZoomFactor)
|
|
37
|
+
};
|
|
47
38
|
/**
|
|
48
39
|
*
|
|
49
40
|
* @param {number} windowId
|
|
@@ -53,58 +44,46 @@ const setZoom = async (windowId, zoomFactor, minZoomLevel, maxZoomLevel) => {
|
|
|
53
44
|
* @returns
|
|
54
45
|
*/
|
|
55
46
|
const setZoomDelta = async (windowId, getDelta, getMinZoomLevel, getMaxZoomLevel) => {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
}
|
|
62
|
-
|
|
47
|
+
const delta = getDelta();
|
|
48
|
+
const minZoomLevel = getMinZoomLevel();
|
|
49
|
+
const maxZoomLevel = getMaxZoomLevel();
|
|
50
|
+
const currentZoomLevel = await ParentIpc.invoke('ElectronWindow.executeWebContentsFunction', windowId, 'getZoomLevel');
|
|
51
|
+
return setZoom(windowId, currentZoomLevel + delta, minZoomLevel, maxZoomLevel);
|
|
52
|
+
};
|
|
63
53
|
const getMinZoomLevel = () => {
|
|
64
|
-
|
|
65
|
-
}
|
|
66
|
-
|
|
54
|
+
return -3;
|
|
55
|
+
};
|
|
67
56
|
const getMaxZoomLevel = () => {
|
|
68
|
-
|
|
69
|
-
}
|
|
70
|
-
|
|
57
|
+
return 3;
|
|
58
|
+
};
|
|
71
59
|
const getZoomInDelta = () => {
|
|
72
|
-
|
|
73
|
-
}
|
|
74
|
-
|
|
60
|
+
return 0.2;
|
|
61
|
+
};
|
|
75
62
|
const getZoomOutDelta = () => {
|
|
76
|
-
|
|
77
|
-
}
|
|
78
|
-
|
|
63
|
+
return -0.2;
|
|
64
|
+
};
|
|
79
65
|
const getDefaultZoomLevel = () => {
|
|
80
|
-
|
|
81
|
-
}
|
|
82
|
-
|
|
66
|
+
return 0;
|
|
67
|
+
};
|
|
83
68
|
export const zoomIn = (windowId) => {
|
|
84
|
-
|
|
85
|
-
}
|
|
86
|
-
|
|
69
|
+
return setZoomDelta(windowId, getZoomInDelta, getMinZoomLevel, getMaxZoomLevel);
|
|
70
|
+
};
|
|
87
71
|
export const zoomOut = (windowId) => {
|
|
88
|
-
|
|
89
|
-
}
|
|
90
|
-
|
|
72
|
+
return setZoomDelta(windowId, getZoomOutDelta, getMinZoomLevel, getMaxZoomLevel);
|
|
73
|
+
};
|
|
91
74
|
export const zoomReset = (windowId) => {
|
|
92
|
-
|
|
93
|
-
}
|
|
94
|
-
|
|
75
|
+
return setZoom(windowId, getDefaultZoomLevel(), getMinZoomLevel(), getMaxZoomLevel());
|
|
76
|
+
};
|
|
95
77
|
export const getZoom = (windowId) => {
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
}
|
|
99
|
-
|
|
78
|
+
// TODO zoom level should be stored in shared process
|
|
79
|
+
return ParentIpc.invoke('ElectronWindow.getZoom', windowId);
|
|
80
|
+
};
|
|
100
81
|
export const focus = (windowId) => {
|
|
101
|
-
|
|
102
|
-
}
|
|
103
|
-
|
|
82
|
+
return ParentIpc.invoke('ElectronWindow.executeWebContentsFunction', windowId, 'focus');
|
|
83
|
+
};
|
|
104
84
|
export const handleClose = (windowId) => {
|
|
105
|
-
|
|
106
|
-
}
|
|
107
|
-
|
|
85
|
+
// TODO
|
|
86
|
+
};
|
|
108
87
|
export const getFocusedWindowId = () => {
|
|
109
|
-
|
|
110
|
-
}
|
|
88
|
+
return ParentIpc.invoke('ElectronWindow.getFocusedWindowId');
|
|
89
|
+
};
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import * as ElectronWindowAbout from './ElectronWindowAbout.js'
|
|
2
|
-
|
|
3
|
-
export const name = 'ElectronWindowAbout'
|
|
4
|
-
|
|
1
|
+
import * as ElectronWindowAbout from './ElectronWindowAbout.js';
|
|
2
|
+
export const name = 'ElectronWindowAbout';
|
|
5
3
|
export const Commands = {
|
|
6
|
-
|
|
7
|
-
}
|
|
4
|
+
open: ElectronWindowAbout.open,
|
|
5
|
+
};
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import * as ElectronWindowProcessExplorer from './ElectronWindowProcessExplorer.js'
|
|
2
|
-
|
|
3
|
-
export const name = 'ElectronWindowProcessExplorer'
|
|
4
|
-
|
|
1
|
+
import * as ElectronWindowProcessExplorer from './ElectronWindowProcessExplorer.js';
|
|
2
|
+
export const name = 'ElectronWindowProcessExplorer';
|
|
5
3
|
export const Commands = {
|
|
6
|
-
|
|
7
|
-
}
|
|
4
|
+
open: ElectronWindowProcessExplorer.open,
|
|
5
|
+
};
|