Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
microsoft
GitHub Repository: microsoft/vscode
Path: blob/main/src/vs/workbench/contrib/debug/common/disassemblyViewInput.ts
3296 views
1
/*---------------------------------------------------------------------------------------------
2
* Copyright (c) Microsoft Corporation. All rights reserved.
3
* Licensed under the MIT License. See License.txt in the project root for license information.
4
*--------------------------------------------------------------------------------------------*/
5
6
import { EditorInput } from '../../../common/editor/editorInput.js';
7
import { localize } from '../../../../nls.js';
8
import { ThemeIcon } from '../../../../base/common/themables.js';
9
import { Codicon } from '../../../../base/common/codicons.js';
10
import { registerIcon } from '../../../../platform/theme/common/iconRegistry.js';
11
12
const DisassemblyEditorIcon = registerIcon('disassembly-editor-label-icon', Codicon.debug, localize('disassemblyEditorLabelIcon', 'Icon of the disassembly editor label.'));
13
14
export class DisassemblyViewInput extends EditorInput {
15
16
static readonly ID = 'debug.disassemblyView.input';
17
18
override get typeId(): string {
19
return DisassemblyViewInput.ID;
20
}
21
22
static _instance: DisassemblyViewInput;
23
static get instance() {
24
if (!DisassemblyViewInput._instance || DisassemblyViewInput._instance.isDisposed()) {
25
DisassemblyViewInput._instance = new DisassemblyViewInput();
26
}
27
28
return DisassemblyViewInput._instance;
29
}
30
31
readonly resource = undefined;
32
33
override getName(): string {
34
return localize('disassemblyInputName', "Disassembly");
35
}
36
37
override getIcon(): ThemeIcon {
38
return DisassemblyEditorIcon;
39
}
40
41
override matches(other: unknown): boolean {
42
return other instanceof DisassemblyViewInput;
43
}
44
45
}
46
47