Skip to content

Commit e592885

Browse files
committed
1 parent af979ba commit e592885

14 files changed

Lines changed: 43 additions & 328 deletions

File tree

extensions/git/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -878,7 +878,7 @@
878878
],
879879
"description": "%config.path%",
880880
"default": null,
881-
"isExecutable": true
881+
"scope": "application"
882882
},
883883
"git.autoRepositoryDetection": {
884884
"type": "boolean",

extensions/typescript-language-features/package.json

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,7 @@
7171
],
7272
"default": null,
7373
"description": "%typescript.npm%",
74-
"isExecutable": true,
75-
"scope": "window"
74+
"scope": "application"
7675
},
7776
"typescript.check.npmIsInstalled": {
7877
"type": "boolean",
@@ -118,8 +117,7 @@
118117
},
119118
"default": [],
120119
"description": "%typescript.tsserver.pluginPaths%",
121-
"scope": "window",
122-
"isExecutable": true
120+
"scope": "application"
123121
},
124122
"typescript.tsserver.trace": {
125123
"type": "string",

src/vs/platform/configuration/common/configurationRegistry.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,6 @@ export enum ConfigurationScope {
6969

7070
export interface IConfigurationPropertySchema extends IJSONSchema {
7171
overridable?: boolean;
72-
isExecutable?: boolean;
7372
scope?: ConfigurationScope;
7473
notMultiRootAdopted?: boolean;
7574
included?: boolean;

src/vs/workbench/parts/execution/electron-browser/execution.contribution.ts

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import { ITerminalService } from 'vs/workbench/parts/execution/common/execution'
1515
import { MenuId, MenuRegistry } from 'vs/platform/actions/common/actions';
1616
import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService';
1717
import { KeyMod, KeyCode } from 'vs/base/common/keyCodes';
18-
import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry';
18+
import { Extensions, IConfigurationRegistry, ConfigurationScope } from 'vs/platform/configuration/common/configurationRegistry';
1919
import { ITerminalService as IIntegratedTerminalService, KEYBINDING_CONTEXT_TERMINAL_NOT_FOCUSED } from 'vs/workbench/parts/terminal/common/terminal';
2020
import { getDefaultTerminalWindows, getDefaultTerminalLinuxReady, DEFAULT_TERMINAL_OSX, ITerminalConfiguration } from 'vs/workbench/parts/execution/electron-browser/terminal';
2121
import { WinTerminalService, MacTerminalService, LinuxTerminalService } from 'vs/workbench/parts/execution/electron-browser/terminalService';
@@ -52,26 +52,25 @@ getDefaultTerminalLinuxReady().then(defaultTerminalLinux => {
5252
'external'
5353
],
5454
'description': nls.localize('explorer.openInTerminalKind', "Customizes what kind of terminal to launch."),
55-
'default': 'integrated',
56-
'isExecutable': false
55+
'default': 'integrated'
5756
},
5857
'terminal.external.windowsExec': {
5958
'type': 'string',
6059
'description': nls.localize('terminal.external.windowsExec', "Customizes which terminal to run on Windows."),
6160
'default': getDefaultTerminalWindows(),
62-
'isExecutable': true
61+
'scope': ConfigurationScope.APPLICATION
6362
},
6463
'terminal.external.osxExec': {
6564
'type': 'string',
6665
'description': nls.localize('terminal.external.osxExec', "Customizes which terminal application to run on OS X."),
6766
'default': DEFAULT_TERMINAL_OSX,
68-
'isExecutable': true
67+
'scope': ConfigurationScope.APPLICATION
6968
},
7069
'terminal.external.linuxExec': {
7170
'type': 'string',
7271
'description': nls.localize('terminal.external.linuxExec', "Customizes which terminal to run on Linux."),
7372
'default': defaultTerminalLinux,
74-
'isExecutable': true
73+
'scope': ConfigurationScope.APPLICATION
7574
}
7675
}
7776
});

src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts

Lines changed: 0 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ import { IContextMenuService } from 'vs/platform/contextview/browser/contextView
2525
import { SettingsGroupTitleWidget, EditPreferenceWidget, SettingsHeaderWidget, DefaultSettingsHeaderWidget, FloatingClickWidget } from 'vs/workbench/parts/preferences/browser/preferencesWidgets';
2626
import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry';
2727
import { RangeHighlightDecorations } from 'vs/workbench/browser/parts/editor/rangeDecorations';
28-
import { IMarkerService, IMarkerData, MarkerSeverity } from 'vs/platform/markers/common/markers';
2928
import { ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents';
3029
import { ModelDecorationOptions } from 'vs/editor/common/model/textModel';
3130
import { IWorkspaceContextService, WorkbenchState } from 'vs/platform/workspace/common/workspace';
@@ -188,7 +187,6 @@ export class UserSettingsRenderer extends Disposable implements IPreferencesRend
188187

189188
export class WorkspaceSettingsRenderer extends UserSettingsRenderer implements IPreferencesRenderer<ISetting> {
190189

191-
private unsupportedSettingsRenderer: UnsupportedSettingsRenderer;
192190
private workspaceConfigurationRenderer: WorkspaceConfigurationRenderer;
193191

194192
constructor(editor: ICodeEditor, preferencesModel: SettingsEditorModel,
@@ -198,7 +196,6 @@ export class WorkspaceSettingsRenderer extends UserSettingsRenderer implements I
198196
@IInstantiationService instantiationService: IInstantiationService
199197
) {
200198
super(editor, preferencesModel, preferencesService, configurationService, instantiationService);
201-
this.unsupportedSettingsRenderer = this._register(instantiationService.createInstance(UnsupportedSettingsRenderer, editor, preferencesModel));
202199
this.workspaceConfigurationRenderer = this._register(instantiationService.createInstance(WorkspaceConfigurationRenderer, editor, preferencesModel));
203200
}
204201

@@ -213,33 +210,25 @@ export class WorkspaceSettingsRenderer extends UserSettingsRenderer implements I
213210

214211
public render(): void {
215212
super.render();
216-
this.unsupportedSettingsRenderer.render();
217213
this.workspaceConfigurationRenderer.render(this.getAssociatedPreferencesModel());
218214
}
219215
}
220216

221217
export class FolderSettingsRenderer extends UserSettingsRenderer implements IPreferencesRenderer<ISetting> {
222218

223-
private unsupportedSettingsRenderer: UnsupportedSettingsRenderer;
224-
225219
constructor(editor: ICodeEditor, preferencesModel: SettingsEditorModel,
226220
@IPreferencesService preferencesService: IPreferencesService,
227221
@ITelemetryService telemetryService: ITelemetryService,
228222
@IConfigurationService configurationService: IConfigurationService,
229223
@IInstantiationService instantiationService: IInstantiationService
230224
) {
231225
super(editor, preferencesModel, preferencesService, configurationService, instantiationService);
232-
this.unsupportedSettingsRenderer = this._register(instantiationService.createInstance(UnsupportedSettingsRenderer, editor, preferencesModel));
233226
}
234227

235228
protected createHeader(): void {
236229
this._register(new SettingsHeaderWidget(this.editor, '')).setMessage(nls.localize('emptyFolderSettingsHeader', "Place your folder settings here to overwrite those from the Workspace Settings."));
237230
}
238231

239-
public render(): void {
240-
super.render();
241-
this.unsupportedSettingsRenderer.render();
242-
}
243232
}
244233

245234
export class DefaultSettingsRenderer extends Disposable implements IPreferencesRenderer<ISetting> {
@@ -1312,63 +1301,6 @@ class SettingHighlighter extends Disposable {
13121301
}
13131302
}
13141303

1315-
class UnsupportedSettingsRenderer extends Disposable {
1316-
1317-
private renderingDelayer: Delayer<void> = new Delayer<void>(200);
1318-
1319-
constructor(
1320-
private editor: ICodeEditor,
1321-
private settingsEditorModel: SettingsEditorModel,
1322-
@IMarkerService private markerService: IMarkerService
1323-
) {
1324-
super();
1325-
this._register(this.editor.getModel().onDidChangeContent(() => this.renderingDelayer.trigger(() => this.render())));
1326-
}
1327-
1328-
public render(): void {
1329-
const configurationRegistry = Registry.as<IConfigurationRegistry>(ConfigurationExtensions.Configuration).getConfigurationProperties();
1330-
const markerData: IMarkerData[] = [];
1331-
for (const settingsGroup of this.settingsEditorModel.settingsGroups) {
1332-
for (const section of settingsGroup.sections) {
1333-
for (const setting of section.settings) {
1334-
if (this.settingsEditorModel.configurationTarget === ConfigurationTarget.WORKSPACE || this.settingsEditorModel.configurationTarget === ConfigurationTarget.WORKSPACE_FOLDER) {
1335-
// Show warnings for executable settings
1336-
if (configurationRegistry[setting.key] && configurationRegistry[setting.key].isExecutable) {
1337-
markerData.push({
1338-
severity: MarkerSeverity.Warning,
1339-
startLineNumber: setting.keyRange.startLineNumber,
1340-
startColumn: setting.keyRange.startColumn,
1341-
endLineNumber: setting.keyRange.endLineNumber,
1342-
endColumn: setting.keyRange.endColumn,
1343-
message: this.getMarkerMessage(setting.key)
1344-
});
1345-
}
1346-
}
1347-
}
1348-
}
1349-
}
1350-
if (markerData.length) {
1351-
this.markerService.changeOne('preferencesEditor', this.settingsEditorModel.uri, markerData);
1352-
} else {
1353-
this.markerService.remove('preferencesEditor', [this.settingsEditorModel.uri]);
1354-
}
1355-
}
1356-
1357-
private getMarkerMessage(settingKey: string): string {
1358-
switch (settingKey) {
1359-
case 'php.validate.executablePath':
1360-
return nls.localize('unsupportedPHPExecutablePathSetting', "This setting must be a User Setting. To configure PHP for the workspace, open a PHP file and click on 'PHP Path' in the status bar.");
1361-
default:
1362-
return nls.localize('unsupportedWorkspaceSetting', "This setting must be a User Setting.");
1363-
}
1364-
}
1365-
1366-
public dispose(): void {
1367-
this.markerService.remove('preferencesEditor', [this.settingsEditorModel.uri]);
1368-
super.dispose();
1369-
}
1370-
}
1371-
13721304
class WorkspaceConfigurationRenderer extends Disposable {
13731305

13741306
private decorationIds: string[] = [];

src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.ts

Lines changed: 0 additions & 82 deletions
This file was deleted.

src/vs/workbench/services/configuration/common/configuration.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,6 @@ export const FOLDER_SETTINGS_PATH = `${FOLDER_CONFIG_FOLDER_NAME}/${FOLDER_SETTI
1313
export const IWorkspaceConfigurationService = createDecorator<IWorkspaceConfigurationService>('configurationService');
1414

1515
export interface IWorkspaceConfigurationService extends IConfigurationService {
16-
/**
17-
* Returns untrusted configuration keys for the current workspace.
18-
*/
19-
getUnsupportedWorkspaceKeys(): string[];
2016
}
2117

2218
export const defaultSettingsSchemaId = 'vscode://schemas/settings/default';

src/vs/workbench/services/configuration/common/configurationExtensionPoint.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ const configurationEntrySchema: IJSONSchema = {
3232
type: 'object',
3333
properties: {
3434
isExecutable: {
35-
type: 'boolean'
35+
type: 'boolean',
36+
deprecationMessage: 'This property is deprecated. Instead use `scope` property and set it to `application` value.'
3637
},
3738
scope: {
3839
type: 'string',

0 commit comments

Comments
 (0)