SVGHMI: more Widget properties declared ES6 style.
--- a/svghmi/widgets_common.ysl2 Wed May 13 22:22:13 2020 +0200
+++ b/svghmi/widgets_common.ysl2 Wed May 13 22:25:22 2020 +0200
@@ -65,12 +65,13 @@
emit "preamble:widget-base-class" {
||
class Widget {
+ offset = 0;
+ frequency = 10; /* FIXME arbitrary default max freq. Obtain from config ? */
constructor(elt_id,args,indexes,members){
this.element_id = elt_id;
this.element = id(elt_id);
this.args = args;
this.indexes = indexes;
- this.offset = 0;
Object.keys(members).forEach(prop => this[prop]=members[prop]);
}