diff --git a/src/vs/workbench/browser/parts/views/views.ts b/src/vs/workbench/browser/parts/views/views.ts index 5d7714e9e57eda023697d8bdfeb359e3bb5fb434..53b16946f974fecf6c83fecd01a9897af5972d95 100644 --- a/src/vs/workbench/browser/parts/views/views.ts +++ b/src/vs/workbench/browser/parts/views/views.ts @@ -22,7 +22,6 @@ import { registerSingleton } from 'vs/platform/instantiation/common/extensions'; import { IPaneComposite } from 'vs/workbench/common/panecomposite'; import { IPanelService } from 'vs/workbench/services/panel/common/panelService'; import { ServicesAccessor, IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { VIEW_ID as SEARCH_VIEW_ID } from 'vs/workbench/services/search/common/search'; import { ViewPaneContainer } from 'vs/workbench/browser/parts/views/viewPaneContainer'; import { PaneCompositePanel, PanelRegistry, PanelDescriptor, Extensions as PanelExtensions } from 'vs/workbench/browser/panel'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; diff --git a/src/vs/workbench/browser/workbench.contribution.ts b/src/vs/workbench/browser/workbench.contribution.ts index e9070ab9bd38b373375b16bf837ac206076ffeed..b78d10076522426afc4514975177231915af7f13 100644 --- a/src/vs/workbench/browser/workbench.contribution.ts +++ b/src/vs/workbench/browser/workbench.contribution.ts @@ -226,11 +226,6 @@ import { workbenchConfigurationNodeBase } from 'vs/workbench/common/configuratio 'default': false, 'description': nls.localize('viewVisibility', "Controls the visibility of view header actions. View header actions may either be always visible, or only visible when that view is focused or hovered over.") }, - 'workbench.view.experimental.allowMovingToNewContainer': { - 'type': 'boolean', - 'default': true, - 'description': nls.localize('movingViewContainer', "Controls whether specific views will have a context menu entry allowing them to be moved to a new container. Currently, this setting only affects the outline view and views contributed by extensions.") - }, 'workbench.fontAliasing': { 'type': 'string', 'enum': ['default', 'antialiased', 'none', 'auto'], diff --git a/src/vs/workbench/services/views/browser/viewDescriptorService.ts b/src/vs/workbench/services/views/browser/viewDescriptorService.ts index 5e0a0ca3c9c903a9c99b4d9873ad65be54de151b..1249935da054dbed81ca3227fcc011f75c5583b3 100644 --- a/src/vs/workbench/services/views/browser/viewDescriptorService.ts +++ b/src/vs/workbench/services/views/browser/viewDescriptorService.ts @@ -14,8 +14,6 @@ import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { registerSingleton } from 'vs/platform/instantiation/common/extensions'; import { Event, Emitter } from 'vs/base/common/event'; import { firstIndex } from 'vs/base/common/arrays'; -import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { VIEW_ID as SEARCH_VIEW_ID } from 'vs/workbench/services/search/common/search'; class CounterSet implements IReadableSet { @@ -219,8 +217,7 @@ export class ViewDescriptorService extends Disposable implements IViewDescriptor constructor( @IContextKeyService private readonly contextKeyService: IContextKeyService, @IStorageService private readonly storageService: IStorageService, - @IExtensionService private readonly extensionService: IExtensionService, - @IConfigurationService private readonly configurationService: IConfigurationService + @IExtensionService private readonly extensionService: IExtensionService ) { super(); @@ -256,33 +253,6 @@ export class ViewDescriptorService extends Disposable implements IViewDescriptor this._register(this.storageService.onDidChangeStorage((e) => { this.onDidStorageChange(e); })); this._register(this.extensionService.onDidRegisterExtensions(() => this.onDidRegisterExtensions())); - - this._register(this.configurationService.onDidChangeConfiguration((changeEvent) => { - if (changeEvent.affectedKeys.find(key => key === 'workbench.view.experimental.allowMovingToNewContainer')) { - if (this.viewsCanMoveSettingValue) { - return; - } - - // update all moved views to their default locations - for (const viewId of this.cachedViewInfo.keys()) { - if (viewId === SEARCH_VIEW_ID) { - continue; - } - - const viewDescriptor = this.getViewDescriptor(viewId); - const viewLocation = this.getViewContainer(viewId); - const defaultLocation = this.getDefaultContainer(viewId); - - if (viewDescriptor && viewLocation && defaultLocation && defaultLocation !== viewLocation) { - this.moveViews([viewDescriptor], viewLocation, defaultLocation); - } - } - } - })); - } - - private get viewsCanMoveSettingValue(): boolean { - return !!this.configurationService.getValue('workbench.view.experimental.allowMovingToNewContainer'); } private registerGroupedViews(groupedViews: Map): void { @@ -379,7 +349,7 @@ export class ViewDescriptorService extends Disposable implements IViewDescriptor } private shouldGenerateContainer(containerInfo: ICachedViewContainerInfo): boolean { - return !!containerInfo.sourceViewId && containerInfo.location !== undefined && (this.viewsCanMoveSettingValue || containerInfo.sourceViewId === SEARCH_VIEW_ID); + return !!containerInfo.sourceViewId && containerInfo.location !== undefined; } private onDidDeregisterViews(views: IViewDescriptor[], viewContainer: ViewContainer): void {