From d1546d83f6aca8b604bf44f5c9086dfd79fd34ff Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Tue, 5 Feb 2019 11:09:56 +0100 Subject: [PATCH] :lipstick: --- src/vs/platform/list/browser/listService.ts | 60 +++++++++++++-------- 1 file changed, 39 insertions(+), 21 deletions(-) diff --git a/src/vs/platform/list/browser/listService.ts b/src/vs/platform/list/browser/listService.ts index 0966123e57d..0a26a9aebf4 100644 --- a/src/vs/platform/list/browser/listService.ts +++ b/src/vs/platform/list/browser/listService.ts @@ -232,27 +232,6 @@ function getSharedListStyleSheet(): HTMLStyleElement { return sharedListStyleSheet; } -let sharedTreeStyleSheet: HTMLStyleElement; -function getSharedTreeStyleSheet(): HTMLStyleElement { - if (!sharedTreeStyleSheet) { - sharedTreeStyleSheet = createStyleSheet(); - } - - return sharedTreeStyleSheet; -} - -function handleTreeController(configuration: ITreeConfiguration, instantiationService: IInstantiationService): ITreeConfiguration { - if (!configuration.controller) { - configuration.controller = instantiationService.createInstance(WorkbenchTreeController, {}); - } - - if (!configuration.styler) { - configuration.styler = new DefaultTreestyler(getSharedTreeStyleSheet()); - } - - return configuration; -} - export class WorkbenchList extends List { readonly contextKeyService: IContextKeyService; @@ -408,6 +387,36 @@ export class WorkbenchPagedList extends PagedList { } } +/** + * @deprecated + */ +let sharedTreeStyleSheet: HTMLStyleElement; +function getSharedTreeStyleSheet(): HTMLStyleElement { + if (!sharedTreeStyleSheet) { + sharedTreeStyleSheet = createStyleSheet(); + } + + return sharedTreeStyleSheet; +} + +/** + * @deprecated + */ +function handleTreeController(configuration: ITreeConfiguration, instantiationService: IInstantiationService): ITreeConfiguration { + if (!configuration.controller) { + configuration.controller = instantiationService.createInstance(WorkbenchTreeController, {}); + } + + if (!configuration.styler) { + configuration.styler = new DefaultTreestyler(getSharedTreeStyleSheet()); + } + + return configuration; +} + +/** + * @deprecated + */ export class WorkbenchTree extends Tree { readonly contextKeyService: IContextKeyService; @@ -502,6 +511,9 @@ export class WorkbenchTree extends Tree { } } +/** + * @deprecated + */ function massageControllerOptions(options: IControllerOptions): IControllerOptions { if (typeof options.keyboardSupport !== 'boolean') { options.keyboardSupport = false; @@ -514,6 +526,9 @@ function massageControllerOptions(options: IControllerOptions): IControllerOptio return options; } +/** + * @deprecated + */ export class WorkbenchTreeController extends DefaultController { protected disposables: IDisposable[] = []; @@ -559,6 +574,9 @@ export interface IResourceResultsNavigationOptions { openOnFocus: boolean; } +/** + * @deprecated + */ export class TreeResourceNavigator extends Disposable { private readonly _openResource = new Emitter();