public abstract static class TaskUiUtil.ComboBoxUpdater<T> extends TaskUiUtil.RemoteFetchTask<java.util.Collection<T>>
Task.Backgroundable, Task.ConditionalModal, Task.Modal, Task.NotificationInfo, Task.WithResult<T,E extends java.lang.Exception>| Modifier and Type | Field and Description |
|---|---|
protected javax.swing.JComboBox<T> |
myComboBox |
myException, myResultmyBackgroundOptionALWAYS_BACKGROUND, DEAF| Constructor and Description |
|---|
ComboBoxUpdater(Project project,
java.lang.String title,
javax.swing.JComboBox<T> comboBox) |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
addSelectedItemIfMissing() |
T |
getExtraItem()
Return extra item like "All projects", which will be added as first item after every combo box update.
|
T |
getSelectedItem()
Return item to select after every combo box update.
|
protected void |
handleError() |
protected void |
updateUI() |
fetch, notifyFinished, runisConditionalModal, isModal, processSentToBackground, shouldStartInBackgroundasBackgroundable, asModal, getCancelText, getCancelTooltipText, getNotificationInfo, getProject, getTitle, isCancellable, isHeadless, onCancel, onError, onFinished, onSuccess, onThrowable, queue, setCancelText, setCancelTooltipText, setTitle, whereToRunCallbacksprotected final javax.swing.JComboBox<T> myComboBox
public T getExtraItem()
public T getSelectedItem()
getExtraItem().
If returned value is not present in the list it will be added depending on policy set by addSelectedItemIfMissing().addSelectedItemIfMissing()protected boolean addSelectedItemIfMissing()
getSelectedItem() should be forcibly added to the combo box.protected void updateUI()
updateUI in class TaskUiUtil.RemoteFetchTask<java.util.Collection<T>>protected void handleError()