From 25696078d9408ff8515745abf75ad9b220cd278a Mon Sep 17 00:00:00 2001 From: Sunil Shetye Date: Thu, 23 Aug 2018 12:17:37 +0530 Subject: use consistent display of variables --- js/Sources/GEN_SQR.js | 12 ++++++------ js/Sources/GEN_SQR.pickle | 24 +++++++++++++----------- js/Sources/PULSE_SC.js | 12 ++++++------ js/Sources/PULSE_SC.pickle | 24 +++++++++++++----------- 4 files changed, 38 insertions(+), 34 deletions(-) (limited to 'js/Sources') diff --git a/js/Sources/GEN_SQR.js b/js/Sources/GEN_SQR.js index ff2f90ef..e7765db5 100644 --- a/js/Sources/GEN_SQR.js +++ b/js/Sources/GEN_SQR.js @@ -55,7 +55,7 @@ function GEN_SQR() { } GEN_SQR.prototype.get = function GEN_SQR() { var options = { - scicos_context.Amin:[Bitems,scicos_context.Amin], + scicos_context.Amin:[this.Bitems,this.scicos_context.Amin], } return options; } @@ -65,16 +65,16 @@ function GEN_SQR() { this.exprs = this.graphics.exprs; var Btitre = "Set GEN_SQR parameters"; var Exprs0 = [["Amin"],["Amax"],["rule"],["F"]]; - var Bitems = [["Minimum Value"],["Maximum Value"],["Initial Value( 1= Minimum Value 2= Maximum Value)"],["Period (sec)"]]; + this.Bitems = [["Minimum Value"],["Maximum Value"],["Initial Value( 1= Minimum Value 2= Maximum Value)"],["Period (sec)"]]; var Ss = list("mat",[-1,-1],"mat",[-1,-1],"pol",-1,"pol",-1); var scicos_context = struct(); var ok = false; while (!ok) { var ok = true; - scicos_context.Amin = arguments[0]["scicos_context.Amin"]; - scicos_context.Amax = arguments[0]["scicos_context.Amax"]; - scicos_context.rule = arguments[0]["scicos_context.rule"]; - scicos_context.F = arguments[0]["scicos_context.F"]; + this.scicos_context.Amin = arguments[0]["scicos_context.Amin"]; + this.scicos_context.Amax = arguments[0]["scicos_context.Amax"]; + this.scicos_context.rule = arguments[0]["scicos_context.rule"]; + this.scicos_context.F = arguments[0]["scicos_context.F"]; if (!ok) { return; } diff --git a/js/Sources/GEN_SQR.pickle b/js/Sources/GEN_SQR.pickle index db3ad103..df14bd84 100644 --- a/js/Sources/GEN_SQR.pickle +++ b/js/Sources/GEN_SQR.pickle @@ -4,26 +4,28 @@ p0 ((lp1 S'needcompile' p2 -aS'scicos_context.Amax' +aS'Bitems' p3 -aS'scicos_context.rule' +aS'scicos_context.Amax' p4 -aS'exprs' +aS'scicos_context.rule' p5 -aS'gr_i' +aS'exprs' p6 -aS'graphics' +aS'gr_i' p7 -aS'x' +aS'graphics' p8 -aS'model' +aS'x' p9 -aS'scicos_context.F' +aS'model' p10 -aS'scicos_context.Amin' +aS'scicos_context.F' p11 -atp12 -Rp13 +aS'scicos_context.Amin' +p12 +atp13 +Rp14 .(dp0 S'model.odstate' p1 diff --git a/js/Sources/PULSE_SC.js b/js/Sources/PULSE_SC.js index 2ad17f19..bed27f9c 100644 --- a/js/Sources/PULSE_SC.js +++ b/js/Sources/PULSE_SC.js @@ -50,7 +50,7 @@ function PULSE_SC() { } PULSE_SC.prototype.get = function PULSE_SC() { var options = { - scicos_context.E:[Bitems,scicos_context.E], + scicos_context.E:[this.Bitems,this.scicos_context.E], } return options; } @@ -60,16 +60,16 @@ function PULSE_SC() { this.exprs = this.graphics.exprs; var Btitre = "Set Pulse Generator parameters"; var Exprs0 = [["E"],["W"],["F"],["A"]]; - var Bitems = [["Phase delay (secs):"],["Pulse Width (% of period):"],["Period (secs):"],["Amplitude:"]]; + this.Bitems = [["Phase delay (secs):"],["Pulse Width (% of period):"],["Period (secs):"],["Amplitude:"]]; var Ss = list("pol",-1,"pol",-1,"pol",-1,"mat",[-1,-1]); var scicos_context = struct(); var ok = false; while (!ok) { var ok = true; - scicos_context.E = arguments[0]["scicos_context.E"]; - scicos_context.W = arguments[0]["scicos_context.W"]; - scicos_context.F = arguments[0]["scicos_context.F"]; - scicos_context.A = arguments[0]["scicos_context.A"]; + this.scicos_context.E = arguments[0]["scicos_context.E"]; + this.scicos_context.W = arguments[0]["scicos_context.W"]; + this.scicos_context.F = arguments[0]["scicos_context.F"]; + this.scicos_context.A = arguments[0]["scicos_context.A"]; if (!ok) { return; } diff --git a/js/Sources/PULSE_SC.pickle b/js/Sources/PULSE_SC.pickle index 49a18971..1d112dc6 100644 --- a/js/Sources/PULSE_SC.pickle +++ b/js/Sources/PULSE_SC.pickle @@ -4,26 +4,28 @@ p0 ((lp1 S'needcompile' p2 -aS'scicos_context.W' +aS'Bitems' p3 -aS'exprs' +aS'scicos_context.W' p4 -aS'gr_i' +aS'exprs' p5 -aS'graphics' +aS'gr_i' p6 -aS'x' +aS'graphics' p7 -aS'model' +aS'x' p8 -aS'scicos_context.A' +aS'model' p9 -aS'scicos_context.F' +aS'scicos_context.A' p10 -aS'scicos_context.E' +aS'scicos_context.F' p11 -atp12 -Rp13 +aS'scicos_context.E' +p12 +atp13 +Rp14 .(dp0 S'model.odstate' p1 -- cgit