< prev index next >

src/com/sun/javatest/tool/UIFactory.java

Print this page

        

*** 1256,1266 **** * @param label Label to associate with this component * @return the choice component that was created * @see #createChoice(String) * @see javax.swing.JLabel#setLabelFor */ ! public JComboBox createChoice(String uiKey, JLabel label) { return createChoice(uiKey, false, label); } /** * Combination of the two parameter methods, allowing you to select --- 1256,1266 ---- * @param label Label to associate with this component * @return the choice component that was created * @see #createChoice(String) * @see javax.swing.JLabel#setLabelFor */ ! public <E> JComboBox<E> createChoice(String uiKey, JLabel label) { return createChoice(uiKey, false, label); } /** * Combination of the two parameter methods, allowing you to select
*** 1273,1283 **** * @see #createChoice(String,JLabel) * @see #createChoice(String,boolean) * @see #createChoice(String) * @see javax.swing.JLabel#setLabelFor */ ! public JComboBox createChoice(String uiKey, boolean editable, JLabel label) { JComboBox choice = new JComboBox(); choice.setName(uiKey); setToolTip(choice, uiKey); if (label != null) --- 1273,1283 ---- * @see #createChoice(String,JLabel) * @see #createChoice(String,boolean) * @see #createChoice(String) * @see javax.swing.JLabel#setLabelFor */ ! public <E> JComboBox<E> createChoice(String uiKey, boolean editable, JLabel label) { JComboBox choice = new JComboBox(); choice.setName(uiKey); setToolTip(choice, uiKey); if (label != null)
*** 1317,1328 **** * @param uiKey the base name of the resources to be used for the menu * @param choices the choices to appear in the choice item * @return the choice item that was created * @see #createChoice */ ! public JComboBox createLiteralChoice(String uiKey, Object[] choices) { ! JComboBox choice = new JComboBox(choices); choice.setName(uiKey); setToolTip(choice, uiKey); return choice; } --- 1317,1328 ---- * @param uiKey the base name of the resources to be used for the menu * @param choices the choices to appear in the choice item * @return the choice item that was created * @see #createChoice */ ! public <E> JComboBox<E> createLiteralChoice(String uiKey, E[] choices) { ! JComboBox<E> choice = new JComboBox<>(choices); choice.setName(uiKey); setToolTip(choice, uiKey); return choice; }
*** 1456,1467 **** * <tr><td><i>uiKey</i>.desc <td>the accessible description of the list * </table> * @param uiKey the base name of the resource to be used (currently ignored) * @return the list that was created */ ! public JList createList(String uiKey) { ! JList list = new JList(); list.setName(uiKey); setAccessibleInfo(list, uiKey); return list; } --- 1456,1467 ---- * <tr><td><i>uiKey</i>.desc <td>the accessible description of the list * </table> * @param uiKey the base name of the resource to be used (currently ignored) * @return the list that was created */ ! public <E> JList<E> createList(String uiKey) { ! JList<E> list = new JList<>(); list.setName(uiKey); setAccessibleInfo(list, uiKey); return list; }
*** 1476,1487 **** * </table> * @param uiKey the base name of the resource to be used (currently ignored) * @param model the data model for this list * @return the list that was created */ ! public JList createList(String uiKey, ListModel model) { ! JList list = new JList(model); list.setName(uiKey); setAccessibleInfo(list, uiKey); return list; } --- 1476,1487 ---- * </table> * @param uiKey the base name of the resource to be used (currently ignored) * @param model the data model for this list * @return the list that was created */ ! public <E> JList<E> createList(String uiKey, ListModel<E> model) { ! JList<E> list = new JList<>(model); list.setName(uiKey); setAccessibleInfo(list, uiKey); return list; }
< prev index next >