From 13ade3f7d3072300af499e77e590e48c0f1533de Mon Sep 17 00:00:00 2001 From: Madhusudan Date: Fri, 11 Oct 2019 16:07:25 +0200 Subject: [PATCH 1/3] New feature changes: - Added feature to disable / enable error pop-up - Bumped up the version to 4.0.2 --- package.json | 2 +- src/MicroflowTimer/MicroflowTimer.xml | 5 +++++ src/MicroflowTimer/widget/MicroflowTimer.js | 9 +++++++-- 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index d752bfc..5648387 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "MicroflowTimer", - "version": "4.0.1", + "version": "4.0.2", "description": "", "license": "", "author": "", diff --git a/src/MicroflowTimer/MicroflowTimer.xml b/src/MicroflowTimer/MicroflowTimer.xml index ba8e3e5..590513f 100644 --- a/src/MicroflowTimer/MicroflowTimer.xml +++ b/src/MicroflowTimer/MicroflowTimer.xml @@ -64,6 +64,11 @@ + + + Show error in a pop-up + Behavior + If true, the microflow or nanoflow execution errors will be shown in a pop-up. diff --git a/src/MicroflowTimer/widget/MicroflowTimer.js b/src/MicroflowTimer/widget/MicroflowTimer.js index abcd1d2..59119e9 100644 --- a/src/MicroflowTimer/widget/MicroflowTimer.js +++ b/src/MicroflowTimer/widget/MicroflowTimer.js @@ -18,6 +18,7 @@ define([ firstIntervalAttr: null, intervalAttr: null, timerStatusAttr: null, + showerrorpopup: false, // Internal variables. Non-primitives created in the prototype are shared between all widget instances. _handles: null, @@ -198,7 +199,9 @@ define([ }), error: lang.hitch(this, function(error) { logger.error(this.id + ": An error ocurred while executing microflow: ", error); - mx.ui.error("An error ocurred while executing microflow" + error.message); + if (this.showerrorpopup) { + mx.ui.error("An error ocurred while executing microflow" + error.message); + } }) }; @@ -228,7 +231,9 @@ define([ }), error: lang.hitch(this, function(error) { logger.error(this.id + ": An error ocurred while executing nanoflow: ", error); - mx.ui.error("An error ocurred while executing nanoflow" + error.message); + if (this.showerrorpopup) { + mx.ui.error("An error ocurred while executing nanoflow" + error.message); + } }) }); } From c9fb861d86c62f2293acce17b6074ca198897b60 Mon Sep 17 00:00:00 2001 From: Madhusudan Date: Mon, 14 Oct 2019 17:12:22 +0200 Subject: [PATCH 2/3] New feature changes: - Updated default error pop-up settings to true --- src/MicroflowTimer/MicroflowTimer.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/MicroflowTimer/MicroflowTimer.xml b/src/MicroflowTimer/MicroflowTimer.xml index 590513f..2e3b3ce 100644 --- a/src/MicroflowTimer/MicroflowTimer.xml +++ b/src/MicroflowTimer/MicroflowTimer.xml @@ -65,7 +65,7 @@ - + Show error in a pop-up Behavior If true, the microflow or nanoflow execution errors will be shown in a pop-up. From 6a0b67f13af34edbcd58c27116ff40049720ce0c Mon Sep 17 00:00:00 2001 From: Madhusudan Date: Mon, 14 Oct 2019 17:14:00 +0200 Subject: [PATCH 3/3] New feature changes: - Updated default error pop-up to true --- src/MicroflowTimer/widget/MicroflowTimer.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/MicroflowTimer/widget/MicroflowTimer.js b/src/MicroflowTimer/widget/MicroflowTimer.js index 59119e9..e1250cc 100644 --- a/src/MicroflowTimer/widget/MicroflowTimer.js +++ b/src/MicroflowTimer/widget/MicroflowTimer.js @@ -18,7 +18,7 @@ define([ firstIntervalAttr: null, intervalAttr: null, timerStatusAttr: null, - showerrorpopup: false, + showerrorpopup: true, // Internal variables. Non-primitives created in the prototype are shared between all widget instances. _handles: null,