UNPKG

@sussudio/platform

Version:

Internal APIs for VS Code's service injection the base services.

74 lines (73 loc) 3.44 kB
/*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ import { createDecorator } from '../../instantiation/common/instantiation.mjs'; export var TitleEventSource; (function (TitleEventSource) { /** From the API or the rename command that overrides any other type */ TitleEventSource[(TitleEventSource['Api'] = 0)] = 'Api'; /** From the process name property*/ TitleEventSource[(TitleEventSource['Process'] = 1)] = 'Process'; /** From the VT sequence */ TitleEventSource[(TitleEventSource['Sequence'] = 2)] = 'Sequence'; /** Config changed */ TitleEventSource[(TitleEventSource['Config'] = 3)] = 'Config'; })(TitleEventSource || (TitleEventSource = {})); export var TerminalIpcChannels; (function (TerminalIpcChannels) { /** * Communicates between the renderer process and shared process. */ TerminalIpcChannels['LocalPty'] = 'localPty'; /** * Communicates between the shared process and the pty host process. */ TerminalIpcChannels['PtyHost'] = 'ptyHost'; /** * Deals with logging from the pty host process. */ TerminalIpcChannels['Log'] = 'log'; /** * Enables the detection of unresponsive pty hosts. */ TerminalIpcChannels['Heartbeat'] = 'heartbeat'; })(TerminalIpcChannels || (TerminalIpcChannels = {})); export const IPtyService = createDecorator('ptyService'); export var HeartbeatConstants; (function (HeartbeatConstants) { /** * The duration between heartbeats */ HeartbeatConstants[(HeartbeatConstants['BeatInterval'] = 5000)] = 'BeatInterval'; /** * Defines a multiplier for BeatInterval for how long to wait before starting the second wait * timer. */ HeartbeatConstants[(HeartbeatConstants['FirstWaitMultiplier'] = 1.2)] = 'FirstWaitMultiplier'; /** * Defines a multiplier for BeatInterval for how long to wait before telling the user about * non-responsiveness. The second timer is to avoid informing the user incorrectly when waking * the computer up from sleep */ HeartbeatConstants[(HeartbeatConstants['SecondWaitMultiplier'] = 1)] = 'SecondWaitMultiplier'; /** * How long to wait before telling the user about non-responsiveness when they try to create a * process. This short circuits the standard wait timeouts to tell the user sooner and only * create process is handled to avoid additional perf overhead. */ HeartbeatConstants[(HeartbeatConstants['CreateProcessTimeout'] = 5000)] = 'CreateProcessTimeout'; })(HeartbeatConstants || (HeartbeatConstants = {})); export var TerminalLocation; (function (TerminalLocation) { TerminalLocation[(TerminalLocation['Panel'] = 1)] = 'Panel'; TerminalLocation[(TerminalLocation['Editor'] = 2)] = 'Editor'; })(TerminalLocation || (TerminalLocation = {})); export var TerminalExitReason; (function (TerminalExitReason) { TerminalExitReason[(TerminalExitReason['Unknown'] = 0)] = 'Unknown'; TerminalExitReason[(TerminalExitReason['Shutdown'] = 1)] = 'Shutdown'; TerminalExitReason[(TerminalExitReason['Process'] = 2)] = 'Process'; TerminalExitReason[(TerminalExitReason['User'] = 3)] = 'User'; TerminalExitReason[(TerminalExitReason['Extension'] = 4)] = 'Extension'; })(TerminalExitReason || (TerminalExitReason = {}));