Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
microsoft
GitHub Repository: microsoft/vscode
Path: blob/main/src/vs/workbench/common/composite.ts
3294 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 { Event } from '../../base/common/event.js';
7
8
export interface IComposite {
9
10
/**
11
* An event when the composite gained focus.
12
*/
13
readonly onDidFocus: Event<void>;
14
15
/**
16
* An event when the composite lost focus.
17
*/
18
readonly onDidBlur: Event<void>;
19
20
/**
21
* Returns true if the composite has focus.
22
*/
23
hasFocus(): boolean;
24
25
/**
26
* Returns the unique identifier of this composite.
27
*/
28
getId(): string;
29
30
/**
31
* Returns the name of this composite to show in the title area.
32
*/
33
getTitle(): string | undefined;
34
35
/**
36
* Returns the underlying control of this composite.
37
*/
38
getControl(): ICompositeControl | undefined;
39
40
/**
41
* Asks the underlying control to focus.
42
*/
43
focus(): void;
44
}
45
46
/**
47
* Marker interface for the composite control
48
*/
49
export interface ICompositeControl { }
50
51