From e031e2239df09cfeaa3d65afe4af8751a54da05c Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 16 Apr 2020 16:55:33 -0700 Subject: [PATCH] first commit --- locales/en/package.i18n.json | 3 +-- package.json | 6 ------ package.nls.json | 3 +-- src/constants.ts | 1 - src/extension.ts | 31 +++---------------------------- 5 files changed, 5 insertions(+), 39 deletions(-) diff --git a/locales/en/package.i18n.json b/locales/en/package.i18n.json index 86e67f9b4..4f34f2536 100644 --- a/locales/en/package.i18n.json +++ b/locales/en/package.i18n.json @@ -13,6 +13,5 @@ "deviceSimulatorExpressExtension.configuration.title": "Device Simulator Express configuration", "deviceSimulatorExpressExtension.configuration.properties.configEnvOnChange": "When you change the Python interpreter, the Device Simulator Express will automatically configure itself for the required dependencies.", "deviceSimulatorExpressExtension.configuration.properties.debuggerPort": "The port the Server will listen on for communication with the debugger.", - "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.", - "deviceSimulatorExpressExtension.configuration.properties.previewMode": "Enable this to test out and play with the new Adafruit CLUE simulator!" + "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." } \ No newline at end of file diff --git a/package.json b/package.json index 9d3b633ec..5a8555f52 100644 --- a/package.json +++ b/package.json @@ -144,12 +144,6 @@ "default": 5577, "description": "%deviceSimulatorExpressExtension.configuration.properties.debuggerPort%", "scope": "resource" - }, - "deviceSimulatorExpress.previewMode": { - "type": "boolean", - "default": false, - "description": "%deviceSimulatorExpressExtension.configuration.properties.previewMode%", - "scope": "resource" } } }, diff --git a/package.nls.json b/package.nls.json index ea3ad1667..e662c005a 100644 --- a/package.nls.json +++ b/package.nls.json @@ -13,6 +13,5 @@ "deviceSimulatorExpressExtension.configuration.title": "Device Simulator Express configuration", "deviceSimulatorExpressExtension.configuration.properties.configEnvOnChange": "When you change the Python interpreter, the Device Simulator Express will automatically configure itself for the required dependencies.", "deviceSimulatorExpressExtension.configuration.properties.debuggerPort": "The port the Server will listen on for communication with the debugger.", - "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.", - "deviceSimulatorExpressExtension.configuration.properties.previewMode": "Enable this to test out and play with the new Adafruit CLUE simulator!" + "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." } \ No newline at end of file diff --git a/src/constants.ts b/src/constants.ts index fb77451e7..488a23b5c 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -22,7 +22,6 @@ export const CONFIG = { PYTHON_PATH: "python.pythonPath", SHOW_DEPENDENCY_INSTALL: "deviceSimulatorExpress.showDependencyInstall", SHOW_NEW_FILE_POPUP: "deviceSimulatorExpress.showNewFilePopup", - ENABLE_PREVIEW_MODE: "deviceSimulatorExpress.previewMode", }; export const CONSTANTS = { diff --git a/src/extension.ts b/src/extension.ts index b36de1f12..a57a14c60 100644 --- a/src/extension.ts +++ b/src/extension.ts @@ -311,14 +311,8 @@ export async function activate(context: vscode.ExtensionContext) { const openSimulator: vscode.Disposable = vscode.commands.registerCommand( "deviceSimulatorExpress.common.openSimulator", async () => { - const isPreviewMode = getIsPreviewMode(); - const chosen_device = await vscode.window.showQuickPick( - Object.values(CONSTANTS.DEVICE_NAME_FORMAL).filter( - device => - isPreviewMode || - device !== CONSTANTS.DEVICE_NAME_FORMAL.CLUE - ) + Object.values(CONSTANTS.DEVICE_NAME_FORMAL) ); if (!chosen_device) { @@ -421,14 +415,8 @@ export async function activate(context: vscode.ExtensionContext) { const newFile: vscode.Disposable = vscode.commands.registerCommand( "deviceSimulatorExpress.common.newFile", async () => { - const isPreviewMode = getIsPreviewMode(); - const chosen_device = await vscode.window.showQuickPick( - Object.values(CONSTANTS.DEVICE_NAME_FORMAL).filter( - device => - isPreviewMode || - device !== CONSTANTS.DEVICE_NAME_FORMAL.CLUE - ) + Object.values(CONSTANTS.DEVICE_NAME_FORMAL) ); if (!chosen_device) { @@ -798,14 +786,8 @@ export async function activate(context: vscode.ExtensionContext) { const deployToDevice: vscode.Disposable = vscode.commands.registerCommand( "deviceSimulatorExpress.common.deployToDevice", async () => { - const isPreviewMode = getIsPreviewMode(); - const chosen_device = await vscode.window.showQuickPick( - Object.values(CONSTANTS.DEVICE_NAME_FORMAL).filter( - device => - isPreviewMode || - device !== CONSTANTS.DEVICE_NAME_FORMAL.CLUE - ) + Object.values(CONSTANTS.DEVICE_NAME_FORMAL) ); if (!chosen_device) { @@ -1025,13 +1007,6 @@ export async function activate(context: vscode.ExtensionContext) { } ); - const getIsPreviewMode = (): boolean => { - const isPreviewMode: boolean = vscode.workspace - .getConfiguration() - .get(CONFIG.ENABLE_PREVIEW_MODE); - return isPreviewMode; - }; - context.subscriptions.push( installDependencies, runSimulator,