JAL-3285 build Jalview XML file for current version
[jalview.git] / src / jalview / gui / OptsAndParamsPage.java
index 00c5a92..5b411b4 100644 (file)
@@ -126,7 +126,7 @@ public class OptsAndParamsPage
 
     OptionI option;
 
-    JComboBox<String> val;
+    JComboBox<Object> val;
 
     /**
      * Constructs and adds labels and controls to the panel for one Option
@@ -357,7 +357,7 @@ public class OptsAndParamsPage
     /*
      * drop-down list of choice options (if applicable)
      */
-    JComboBox<String> choicebox;
+    JComboBox<Object> choicebox;
 
     /*
      * radio buttons as an alternative to combo box
@@ -1172,13 +1172,15 @@ public class OptsAndParamsPage
    * @param opt
    * @return
    */
-  protected static JComboBox<String> buildComboBox(OptionI opt)
+  protected static JComboBox<Object> buildComboBox(OptionI opt)
   {
-    JComboBox<String> cb = null;
+    JComboBox<Object> cb = null;
     List<String> displayNames = opt.getDisplayNames();
     if (displayNames != null)
     {
-      cb = JvSwingUtils.buildComboWithTooltips(displayNames,
+      List<Object> displayNamesObjects = new ArrayList<>();
+      displayNamesObjects.addAll(displayNames);
+      cb = JvSwingUtils.buildComboWithTooltips(displayNamesObjects,
               opt.getPossibleValues());
     }
     else