svghmi/widget_dropdown.ysl2
branchsvghmi
changeset 3133 450cd01324ad
parent 3131 2d750e38a4c6
child 3232 7bdb766c2a4d
--- a/svghmi/widget_dropdown.ysl2	Tue Feb 09 08:11:22 2021 +0100
+++ b/svghmi/widget_dropdown.ysl2	Tue Feb 09 17:09:08 2021 +0100
@@ -337,11 +337,17 @@
     param "hmi_element";
     labels("text box button highlight");
     // It is assumed that list content conforms to Array interface.
-||
-    content: [
-    /* TODO : Support HMI:List */
-    ``foreach "arg" | "«@value»",
-    ],
-
-||
+    >   content:
+    choose{
+        // special case when used for language selection
+        when "count(arg) = 1 and arg[1]/@value = '#langs'" {
+            > langs
+        }
+        otherwise {
+            > [\n
+            foreach "arg" | "«@value»",
+            >   ]
+        }
+    }
+    > ,\n
 }