mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-03-31 09:10:30 -04:00
Merge from vscode 8a997f7321ae6612fc0e6eb3eac4f358a6233bfb
This commit is contained in:
@@ -49,6 +49,7 @@ import { ExcludeSettingWidget, IListChangeEvent, IListDataItem, ListSettingWidge
|
||||
import { SETTINGS_EDITOR_COMMAND_SHOW_CONTEXT_MENU } from 'vs/workbench/contrib/preferences/common/preferences';
|
||||
import { IWorkbenchEnvironmentService } from 'vs/workbench/services/environment/common/environmentService';
|
||||
import { ISetting, ISettingsGroup, SettingValueType } from 'vs/workbench/services/preferences/common/preferences';
|
||||
import { IUserDataSyncEnablementService } from 'vs/platform/userDataSync/common/userDataSync';
|
||||
|
||||
const $ = DOM.$;
|
||||
|
||||
@@ -1191,7 +1192,7 @@ export class SettingTreeRenderers {
|
||||
@IInstantiationService private readonly _instantiationService: IInstantiationService,
|
||||
@IContextMenuService private readonly _contextMenuService: IContextMenuService,
|
||||
@IContextViewService private readonly _contextViewService: IContextViewService,
|
||||
@IConfigurationService private readonly _configService: IConfigurationService,
|
||||
@IUserDataSyncEnablementService private readonly _userDataSyncEnablementService: IUserDataSyncEnablementService,
|
||||
) {
|
||||
this.settingActions = [
|
||||
new Action('settings.resetSetting', localize('resetSettingLabel', "Reset Setting"), undefined, undefined, (context: SettingsTreeSettingElement) => {
|
||||
@@ -1235,7 +1236,7 @@ export class SettingTreeRenderers {
|
||||
}
|
||||
|
||||
private getActionsForSetting(setting: ISetting): IAction[] {
|
||||
const enableSync = this._configService.getValue<boolean>('sync.enable');
|
||||
const enableSync = this._userDataSyncEnablementService.isEnabled();
|
||||
return enableSync ?
|
||||
[this._instantiationService.createInstance(StopSyncingSettingAction, setting)] :
|
||||
[];
|
||||
|
||||
Reference in New Issue
Block a user