Methods

(static) buttonDialogResult(index, confirmIndex, buttons) → {object}

Result for a button-row dialog (JRDialog). index = -1 means cancelled. confirmIndex is the button that counts as the affirmative action (-1 = none), which is what showConfirmDialog sets so callers can read result.confirmed.

Parameters:
NameTypeDescription
indexinteger
confirmIndexinteger
buttonsobject
Returns:
Type: 
object

(static) listDialogResult(index) → {object}

Result for a selection-list dialog (JRListDialog). index = -1 means dismissed without choosing. A list dialog has NO buttons at all — its rows are the only focusable thing in it and Back is the exit — so both button fields stay empty and callers branch on optionIndex / cancelled.

It used to take a cancelText and report it as buttonText on dismissal, from when the dialog had a Cancel button. Keeping that would have meant a result naming a control the user was never shown.

Parameters:
NameTypeDescription
indexinteger
Returns:
Type: 
object

(static) makeDialogResult(cancelled, confirmed, buttonIndex, optionIndex, buttonText, value) → {object}

Parameters:
NameTypeDescription
cancelledboolean
confirmedboolean
buttonIndexinteger
optionIndexinteger
buttonTextstring
valuestring
Returns:
Type: 
object

(static) textDialogResult(cancelled, enteredText) → {object}

Result for a text-entry dialog (JRKeyboardDialog). cancelled distinguishes a cancel/back from an intentionally empty entry, so callers can tell them apart.

Parameters:
NameTypeDescription
cancelledboolean
enteredTextstring
Returns:
Type: 
object