public void itemStateChanged(ItemEvent e) { if (e.getStateChange() == ItemEvent.SELECTED) { AdjuPopupPane popup = (AdjuPopupPane) relComponents[LABELS.adjudicationDisagreement.ordinal()]; if (isParent) { String itemValue = (String) ((JComboBox) e.getSource()).getSelectedItem(); if (itemValue.equals("Selected Annotator") || itemValue.equals("Select and Edit")) { String diff = relation.getAdjuDiff(); popup.setAnnValue(diff); popup.setClickable(true); // relComponents[LABELS.adjudicationDisagreement.ordinal()}. } else { popup.annReset(); popup.setClickable(false); } } else { popup.annReset(); popup.setClickable(false); } mainFrame.inputAction((JComponent) e.getSource(), spanButtons); enableRelationType(); } }