Class DialogChooser


  • public class DialogChooser
    extends java.lang.Object
    Since:
    jEdit 5.7pre1
    • Constructor Summary

      Constructors 
      Constructor Description
      DialogChooser()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static int openChooserWindow​(javax.swing.JFrame parent, java.lang.String... choices)
      Show an undecorated modal dialog presenting one button per choice.
      static void openListChooserWindow​(javax.swing.JComponent parent, java.lang.Object initialValue, javax.swing.event.ListSelectionListener listSelectionListener, java.lang.Object[] choices)
      Show an undecorated dialog showing a list of items to choose.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DialogChooser

        public DialogChooser()
    • Method Detail

      • openChooserWindow

        public static int openChooserWindow​(javax.swing.JFrame parent,
                                            java.lang.String... choices)
        Show an undecorated modal dialog presenting one button per choice.
        Parameters:
        parent - the parent frame
        choices - the choices
        Returns:
        the index of the selected choice
        Since:
        jEdit 5.7pre1
      • openListChooserWindow

        public static void openListChooserWindow​(javax.swing.JComponent parent,
                                                 java.lang.Object initialValue,
                                                 javax.swing.event.ListSelectionListener listSelectionListener,
                                                 java.lang.Object[] choices)
        Show an undecorated dialog showing a list of items to choose.
        Parameters:
        parent - the parent component
        initialValue - the initial choosen value
        listSelectionListener - the callback to call when an item is choosen
        choices - the choices
        Since:
        jEdit 5.7pre1