m_EditBut.setEnabled(m_List.getSelectedIndex() > -1); m_LoadOptionsBut.setEnabled(m_List.getSelectedIndex() > -1); m_SaveOptionsBut.setEnabled(m_List.getSelectedIndex() > -1);
m_EditBut.setEnabled(m_List.getSelectedIndices().length == 1); m_LoadOptionsBut.setEnabled(m_List.getSelectedIndices().length == 1); m_SaveOptionsBut.setEnabled(m_List.getSelectedIndices().length == 1);
  private void setButtons(ListSelectionEvent e) {    if (e.getSource() == m_List) {      m_DeleteBut.setEnabled(m_List.getSelectedIndex() > -1);      m_AddBut.setEnabled(true);      m_EditBut.setEnabled(m_List.getSelectedIndex() > -1);      m_LoadOptionsBut.setEnabled(m_List.getSelectedIndex() > -1);      m_SaveOptionsBut.setEnabled(m_List.getSelectedIndex() > -1);    }  }