@sussudio/platform
Version:
Internal APIs for VS Code's service injection the base services.
30 lines (28 loc) • 1.67 kB
text/typescript
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { SingleModifierChord, KeyCodeChord, Keybinding } from '@sussudio/base/common/keybindings.mjs';
import { OperatingSystem } from '@sussudio/base/common/platform.mjs';
import { BaseResolvedKeybinding } from './baseResolvedKeybinding.mjs';
/**
* Do not instantiate. Use KeybindingService to get a ResolvedKeybinding seeded with information about the current kb layout.
*/
export declare class USLayoutResolvedKeybinding extends BaseResolvedKeybinding<KeyCodeChord> {
constructor(chords: KeyCodeChord[], os: OperatingSystem);
private _keyCodeToUILabel;
protected _getLabel(chord: KeyCodeChord): string | null;
protected _getAriaLabel(chord: KeyCodeChord): string | null;
protected _getElectronAccelerator(chord: KeyCodeChord): string | null;
protected _getUserSettingsLabel(chord: KeyCodeChord): string | null;
protected _isWYSIWYG(): boolean;
protected _getChordDispatch(chord: KeyCodeChord): string | null;
static getDispatchStr(chord: KeyCodeChord): string | null;
protected _getSingleModifierChordDispatch(keybinding: KeyCodeChord): SingleModifierChord | null;
/**
* *NOTE*: Check return value for `KeyCode.Unknown`.
*/
private static _scanCodeToKeyCode;
private static _toKeyCodeChord;
static resolveKeybinding(keybinding: Keybinding, os: OperatingSystem): USLayoutResolvedKeybinding[];
}