mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-03-31 01:00:29 -04:00
Merge from vscode de81ccf04849309f843db21130c806a5783678f7 (#4738)
This commit is contained in:
@@ -91,7 +91,6 @@ export class OpenGlobalSettingsAction extends Action {
|
||||
export class OpenRemoteSettingsAction extends Action {
|
||||
|
||||
static readonly ID = 'workbench.action.openRemoteSettings';
|
||||
static readonly LABEL = nls.localize('openRemoteSettings', "Open User Settings (Remote)");
|
||||
|
||||
constructor(
|
||||
id: string,
|
||||
|
||||
@@ -1220,7 +1220,16 @@ export class SettingsTreeFilter implements ITreeFilter<SettingsTreeElement> {
|
||||
}
|
||||
|
||||
class SettingsTreeDelegate implements IListVirtualDelegate<SettingsTreeGroupChild> {
|
||||
getHeight(element: SettingsTreeElement): number {
|
||||
|
||||
private heightCache = new WeakMap<SettingsTreeGroupChild, number>();
|
||||
|
||||
getHeight(element: SettingsTreeGroupChild): number {
|
||||
const cachedHeight = this.heightCache.get(element);
|
||||
|
||||
if (typeof cachedHeight === 'number') {
|
||||
return cachedHeight;
|
||||
}
|
||||
|
||||
if (element instanceof SettingsTreeGroupElement) {
|
||||
if (element.isFirstGroup) {
|
||||
return 31;
|
||||
@@ -1273,6 +1282,10 @@ class SettingsTreeDelegate implements IListVirtualDelegate<SettingsTreeGroupChil
|
||||
hasDynamicHeight(element: SettingsTreeGroupElement | SettingsTreeSettingElement | SettingsTreeNewExtensionsElement): boolean {
|
||||
return !(element instanceof SettingsTreeGroupElement);
|
||||
}
|
||||
|
||||
setDynamicHeight(element: SettingsTreeGroupChild, height: number): void {
|
||||
this.heightCache.set(element, height);
|
||||
}
|
||||
}
|
||||
|
||||
class NonCollapsibleObjectTreeModel<T> extends ObjectTreeModel<T> {
|
||||
|
||||
Reference in New Issue
Block a user