/** Generic code to set properties appropriately from any of the renderer * fetching methods */ private void configureFrom(Object value, JComponent target, boolean selected, boolean leadSelection) { if (value == null) { value = ""; } setText((value == null) ? "" : value.toString()); setSelected(selected); if (selected) { setParentFocused(checkFocused(target)); } else { setParentFocused(false); } setEnabled(target.isEnabled()); setLeadSelection(leadSelection); setFont(target.getFont()); }
/** Generic code to set properties appropriately from any of the renderer * fetching methods */ private void configureFrom (Object value, JComponent target, boolean selected, boolean leadSelection) { if (value == null) { value = ""; } setText (value == null ? "" : value.toString()); setSelected(selected); if (selected) { setParentFocused(checkFocused(target)); } else { setParentFocused(false); } setEnabled (target.isEnabled()); setLeadSelection (leadSelection); setFont (target.getFont()); }
/** Generic code to set properties appropriately from any of the renderer * fetching methods */ private void configureFrom (Object value, JComponent target, boolean selected, boolean leadSelection) { if (value == null) { value = ""; } setText (value == null ? "" : value.toString()); setSelected(selected); if (selected) { setParentFocused(checkFocused(target)); } else { setParentFocused(false); } setEnabled (target.isEnabled()); setLeadSelection (leadSelection); setFont (target.getFont()); }