Skip to content
This repository was archived by the owner on Dec 23, 2021. It is now read-only.

Commit e39f77f

Browse files
authored
Remove preview mode for CLUE (#336)
1 parent 5d88fc5 commit e39f77f

File tree

5 files changed

+5
-39
lines changed

5 files changed

+5
-39
lines changed

locales/en/package.i18n.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,5 @@
1313
"deviceSimulatorExpressExtension.configuration.title": "Device Simulator Express configuration",
1414
"deviceSimulatorExpressExtension.configuration.properties.configEnvOnChange": "When you change the Python interpreter, the Device Simulator Express will automatically configure itself for the required dependencies.",
1515
"deviceSimulatorExpressExtension.configuration.properties.debuggerPort": "The port the Server will listen on for communication with the debugger.",
16-
"deviceSimulatorExpressExtension.configuration.properties.dependencyChecker": "Whether or not to ask if we can download dependencies. If unchecked, the extension will default to never download dependencies, except when automatically creating a virtual environment in the extension files.",
17-
"deviceSimulatorExpressExtension.configuration.properties.previewMode": "Enable this to test out and play with the new Adafruit CLUE simulator!"
16+
"deviceSimulatorExpressExtension.configuration.properties.dependencyChecker": "Whether or not to ask if we can download dependencies. If unchecked, the extension will default to never download dependencies, except when automatically creating a virtual environment in the extension files."
1817
}

package.json

-6
Original file line numberDiff line numberDiff line change
@@ -144,12 +144,6 @@
144144
"default": 5577,
145145
"description": "%deviceSimulatorExpressExtension.configuration.properties.debuggerPort%",
146146
"scope": "resource"
147-
},
148-
"deviceSimulatorExpress.previewMode": {
149-
"type": "boolean",
150-
"default": false,
151-
"description": "%deviceSimulatorExpressExtension.configuration.properties.previewMode%",
152-
"scope": "resource"
153147
}
154148
}
155149
},

package.nls.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,5 @@
1313
"deviceSimulatorExpressExtension.configuration.title": "Device Simulator Express configuration",
1414
"deviceSimulatorExpressExtension.configuration.properties.configEnvOnChange": "When you change the Python interpreter, the Device Simulator Express will automatically configure itself for the required dependencies.",
1515
"deviceSimulatorExpressExtension.configuration.properties.debuggerPort": "The port the Server will listen on for communication with the debugger.",
16-
"deviceSimulatorExpressExtension.configuration.properties.dependencyChecker": "Whether or not to ask for dependency downloads. If unchecked, the extension will default to never download dependencies, except when automatically creating a virtual environment in the extension files.",
17-
"deviceSimulatorExpressExtension.configuration.properties.previewMode": "Enable this to test out and play with the new Adafruit CLUE simulator!"
16+
"deviceSimulatorExpressExtension.configuration.properties.dependencyChecker": "Whether or not to ask for dependency downloads. If unchecked, the extension will default to never download dependencies, except when automatically creating a virtual environment in the extension files."
1817
}

src/constants.ts

-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ export const CONFIG = {
2222
PYTHON_PATH: "python.pythonPath",
2323
SHOW_DEPENDENCY_INSTALL: "deviceSimulatorExpress.showDependencyInstall",
2424
SHOW_NEW_FILE_POPUP: "deviceSimulatorExpress.showNewFilePopup",
25-
ENABLE_PREVIEW_MODE: "deviceSimulatorExpress.previewMode",
2625
};
2726

2827
export const CONSTANTS = {

src/extension.ts

+3-28
Original file line numberDiff line numberDiff line change
@@ -310,14 +310,8 @@ export async function activate(context: vscode.ExtensionContext) {
310310
const openSimulator: vscode.Disposable = vscode.commands.registerCommand(
311311
"deviceSimulatorExpress.common.openSimulator",
312312
async () => {
313-
const isPreviewMode = getIsPreviewMode();
314-
315313
const chosen_device = await vscode.window.showQuickPick(
316-
Object.values(CONSTANTS.DEVICE_NAME_FORMAL).filter(
317-
device =>
318-
isPreviewMode ||
319-
device !== CONSTANTS.DEVICE_NAME_FORMAL.CLUE
320-
)
314+
Object.values(CONSTANTS.DEVICE_NAME_FORMAL)
321315
);
322316

323317
if (!chosen_device) {
@@ -420,14 +414,8 @@ export async function activate(context: vscode.ExtensionContext) {
420414
const newFile: vscode.Disposable = vscode.commands.registerCommand(
421415
"deviceSimulatorExpress.common.newFile",
422416
async () => {
423-
const isPreviewMode = getIsPreviewMode();
424-
425417
const chosen_device = await vscode.window.showQuickPick(
426-
Object.values(CONSTANTS.DEVICE_NAME_FORMAL).filter(
427-
device =>
428-
isPreviewMode ||
429-
device !== CONSTANTS.DEVICE_NAME_FORMAL.CLUE
430-
)
418+
Object.values(CONSTANTS.DEVICE_NAME_FORMAL)
431419
);
432420

433421
if (!chosen_device) {
@@ -797,14 +785,8 @@ export async function activate(context: vscode.ExtensionContext) {
797785
const deployToDevice: vscode.Disposable = vscode.commands.registerCommand(
798786
"deviceSimulatorExpress.common.deployToDevice",
799787
async () => {
800-
const isPreviewMode = getIsPreviewMode();
801-
802788
const chosen_device = await vscode.window.showQuickPick(
803-
Object.values(CONSTANTS.DEVICE_NAME_FORMAL).filter(
804-
device =>
805-
isPreviewMode ||
806-
device !== CONSTANTS.DEVICE_NAME_FORMAL.CLUE
807-
)
789+
Object.values(CONSTANTS.DEVICE_NAME_FORMAL)
808790
);
809791

810792
if (!chosen_device) {
@@ -1024,13 +1006,6 @@ export async function activate(context: vscode.ExtensionContext) {
10241006
}
10251007
);
10261008

1027-
const getIsPreviewMode = (): boolean => {
1028-
const isPreviewMode: boolean = vscode.workspace
1029-
.getConfiguration()
1030-
.get(CONFIG.ENABLE_PREVIEW_MODE);
1031-
return isPreviewMode;
1032-
};
1033-
10341009
context.subscriptions.push(
10351010
installDependencies,
10361011
runSimulator,

0 commit comments

Comments
 (0)