From 482ed941aab73230a560024e37c272b1b398b48a Mon Sep 17 00:00:00 2001 From: Christoph Schlosser Date: Fri, 30 Mar 2018 00:26:33 +0200 Subject: Release 0.3.1 --- CHANGELOG.md | 6 ++++++ package.json | 2 +- src/extension.ts | 17 ++++++++++++++++- 3 files changed, 23 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b471eca..1b6f013 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Change Log +## [0.3.1] + +### Fix + +- Don't create a comment while editing an existing comment. (#67) + ## [0.3.0] ### Features diff --git a/package.json b/package.json index b3ea724..335296c 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "doxdocgen", "displayName": "Doxygen Documentation Generator", "description": "Let me generate Doxygen documentation from your source code for you.", - "version": "0.3.0", + "version": "0.3.1", "publisher": "cschlosser", "engines": { "vscode": "^1.16.0" diff --git a/src/extension.ts b/src/extension.ts index 99cc168..73be843 100644 --- a/src/extension.ts +++ b/src/extension.ts @@ -11,6 +11,12 @@ enum ConfigChangedNotificationOptions { GLOBAL_STORAGE_KEY = "doxdocgen_hide_config_changed_notification", } +enum Version { + CURRENT = "0.3.1", + PREVIOUS = "0.3.0", + KEY = "doxdocgen_version", +} + // this method is called when your extension is activated // your extension is activated the very first time the command is executed export function activate(context: vscode.ExtensionContext) { @@ -18,9 +24,18 @@ export function activate(context: vscode.ExtensionContext) { context.subscriptions.push(parser); + let change: boolean = false; + + const version = context.globalState.get(Version.KEY); + if (version === undefined) { + context.globalState.update(Version.KEY, Version.CURRENT); + } else if (version !== Version.CURRENT) { + change = true; + } + let notificationHideThenable: Thenable; const active = context.globalState.get(ConfigChangedNotificationOptions.GLOBAL_STORAGE_KEY); - if (active === undefined || active !== "false") { + if (change && (active === undefined || active !== "false")) { // tslint:disable-next-line:max-line-length notificationHideThenable = vscode.window.showWarningMessage("DoxDocGen: Config keys have changed. Please check your config!", ConfigChangedNotificationOptions.CHANGED, ConfigChangedNotificationOptions.HIDE); } -- cgit v1.2.3