diff --git a/src/sql/workbench/common/actions.contribution.ts b/src/sql/workbench/common/actions.contribution.ts index c5803692ff..d485b2c77f 100644 --- a/src/sql/workbench/common/actions.contribution.ts +++ b/src/sql/workbench/common/actions.contribution.ts @@ -32,7 +32,7 @@ Registry.as(ConfigExtensions.Configuration).registerConf 'properties': { 'workbench.enablePreviewFeatures': { 'type': 'boolean', - 'default': undefined, + 'default': true, 'description': nls.localize('previewFeatures.configEnable', 'Enable unreleased preview features') } } diff --git a/src/sql/workbench/electron-browser/enablePreviewFeatures.ts b/src/sql/workbench/electron-browser/enablePreviewFeatures.ts index ff8ce68309..ed878dd049 100644 --- a/src/sql/workbench/electron-browser/enablePreviewFeatures.ts +++ b/src/sql/workbench/electron-browser/enablePreviewFeatures.ts @@ -27,44 +27,46 @@ export class EnablePreviewFeatures implements IWorkbenchContribution { @ITelemetryService telemetryService: ITelemetryService, @IConfigurationService configurationService: IConfigurationService ) { - let previewFeaturesEnabled = configurationService.getValue('workbench')['enablePreviewFeatures']; - if (previewFeaturesEnabled || storageService.get(EnablePreviewFeatures.ENABLE_PREVIEW_FEATURES_SHOWN)) { - return; - } - Promise.all([ - windowService.isFocused(), - windowsService.getWindowCount() - ]).then(([focused, count]) => { - if (!focused && count > 1) { - return null; - } - configurationService.updateValue('workbench.enablePreviewFeatures', false); + return; - const enablePreviewFeaturesNotice = localize('enablePreviewFeatures.notice', "Would you like to enable preview features?"); - notificationService.prompt( - Severity.Info, - enablePreviewFeaturesNotice, - [{ - label: localize('enablePreviewFeatures.yes', "Yes"), - run: () => { - configurationService.updateValue('workbench.enablePreviewFeatures', true); - storageService.store(EnablePreviewFeatures.ENABLE_PREVIEW_FEATURES_SHOWN, true); - } - }, { - label: localize('enablePreviewFeatures.no', "No"), - run: () => { - configurationService.updateValue('workbench.enablePreviewFeatures', false); - } - }, { - label: localize('enablePreviewFeatures.never', "No, don't show again"), - run: () => { - configurationService.updateValue('workbench.enablePreviewFeatures', false); - storageService.store(EnablePreviewFeatures.ENABLE_PREVIEW_FEATURES_SHOWN, true); - }, - isSecondary: true - }] - ); - }) - .then(null, onUnexpectedError); + // let previewFeaturesEnabled = configurationService.getValue('workbench')['enablePreviewFeatures']; + // if (previewFeaturesEnabled || storageService.get(EnablePreviewFeatures.ENABLE_PREVIEW_FEATURES_SHOWN)) { + // return; + // } + // Promise.all([ + // windowService.isFocused(), + // windowsService.getWindowCount() + // ]).then(([focused, count]) => { + // if (!focused && count > 1) { + // return null; + // } + // configurationService.updateValue('workbench.enablePreviewFeatures', false); + + // const enablePreviewFeaturesNotice = localize('enablePreviewFeatures.notice', "Would you like to enable preview features?"); + // notificationService.prompt( + // Severity.Info, + // enablePreviewFeaturesNotice, + // [{ + // label: localize('enablePreviewFeatures.yes', "Yes"), + // run: () => { + // configurationService.updateValue('workbench.enablePreviewFeatures', true); + // storageService.store(EnablePreviewFeatures.ENABLE_PREVIEW_FEATURES_SHOWN, true); + // } + // }, { + // label: localize('enablePreviewFeatures.no', "No"), + // run: () => { + // configurationService.updateValue('workbench.enablePreviewFeatures', false); + // } + // }, { + // label: localize('enablePreviewFeatures.never', "No, don't show again"), + // run: () => { + // configurationService.updateValue('workbench.enablePreviewFeatures', false); + // storageService.store(EnablePreviewFeatures.ENABLE_PREVIEW_FEATURES_SHOWN, true); + // }, + // isSecondary: true + // }] + // ); + // }) + // .then(null, onUnexpectedError); } }