Class ConfigComboModel

    • Field Detail

      • EDIT_TEXT

        public static final String EDIT_TEXT
        Translated "Edit Configuration" text.
    • Constructor Detail

      • ConfigComboModel

        public ConfigComboModel()
    • Method Detail

      • getElementAt

        public Object getElementAt​(int index)
        Returns the item at the specified index.

        Notice: The index is shifted upwards by one, because the first element is the "Edit configurations" button.

        Specified by:
        getElementAt in interface ListModel<Object>
        Overrides:
        getElementAt in class DefaultComboBoxModel<Object>
        Returns:
        item at the specified index
      • getSize

        public int getSize()
        Get the amount of items in the combo box. The size is increased by one due to the "Edit Configuration" button.
        Specified by:
        getSize in interface ListModel<Object>
        Overrides:
        getSize in class DefaultComboBoxModel<Object>
        Returns:
        amount of items in the combo box
      • addSelectionListener

        public void addSelectionListener​(IntConsumer selectionListener)
        Add a index listener to the event of a change of the selected index.
        Parameters:
        selectionListener - selected index change listener