diff options
author | Sunil Shetye | 2018-08-29 17:37:00 +0530 |
---|---|---|
committer | Sunil Shetye | 2018-08-29 18:03:04 +0530 |
commit | 6a435095be880c696cb975d859ec730046021a75 (patch) | |
tree | 92a7831d3dc4ecb878f7bd5c896df50c8244f2ee /js/Sources/CLOCK_f.js | |
parent | 352623792d2b9400510599c487540b1e763a7d3c (diff) | |
download | sci2js-6a435095be880c696cb975d859ec730046021a75.tar.gz sci2js-6a435095be880c696cb975d859ec730046021a75.tar.bz2 sci2js-6a435095be880c696cb975d859ec730046021a75.zip |
support arg1 parsing
Diffstat (limited to 'js/Sources/CLOCK_f.js')
-rw-r--r-- | js/Sources/CLOCK_f.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/js/Sources/CLOCK_f.js b/js/Sources/CLOCK_f.js index 291cf09d..306da277 100644 --- a/js/Sources/CLOCK_f.js +++ b/js/Sources/CLOCK_f.js @@ -46,12 +46,15 @@ function CLOCK_f() { return this.x; } CLOCK_f.prototype.get = function CLOCK_f() { + for (i=1;i<=length(this.model.rpar.objs);i+=1) { + var o = this.model.rpar.objs[i-1]; if (typeof(o)=="Block"&&o.gui=="EVTDLY_f") { var path = i; break; } } var newpar = list(); + var xx = this.model.rpar.objs[path-1]; var exprs = xx.graphics.exprs; this.model = xx.model; var t0_old = this.model.firing; @@ -65,12 +68,15 @@ function CLOCK_f() { return options; } CLOCK_f.prototype.set = function CLOCK_f() { + for (i=1;i<=length(this.model.rpar.objs);i+=1) { + var o = this.model.rpar.objs[i-1]; if (typeof(o)=="Block"&&o.gui=="EVTDLY_f") { var path = i; break; } } var newpar = list(); + var xx = this.model.rpar.objs[path-1]; var exprs = xx.graphics.exprs; this.model = xx.model; var t0_old = this.model.firing; @@ -94,6 +100,7 @@ function CLOCK_f() { this.model.rpar = new ScilabDouble([this.dt]); this.model.firing = new ScilabDouble([this.t0]); xx.model = this.model; + this.model.rpar.objs[path-1] = xx; break; } } |