--- a/svghmi/widget_foreach.ysl2 Tue Mar 24 23:07:54 2020 +0100
+++ b/svghmi/widget_foreach.ysl2 Wed Mar 25 13:36:04 2020 +0100
@@ -44,19 +44,14 @@
}
| ]
| },
- | on_click: function(opstr, evt) {
- | console.log(opstr);
- | },
| item_offset: 0,
+ | on_click: foreach_onclick,
}
template "widget[@type='ForEach']", mode="widget_subscribe"{
// param "hmi_element";
- | sub: function(off){
- | foreach_subscribe.call(this,off);
- | },
+ | sub: foreach_subscribe,
+ | unsub: foreach_unsubscribe,
+ | apply_cache: foreach_apply_cache,
+}
- | unsub: function(){
- | foreach_unsubscribe.call(this);
- | },
-}