Methods
(static) buttonDialogResult(index, confirmIndex, buttons, externallyCancelledopt) → {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.
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
index | integer | |||
confirmIndex | integer | |||
buttons | object | |||
externallyCancelled | boolean | <optional> | false |
- Type:
- object
(static) listDialogResult(index, externallyCancelledopt) → {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.
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
index | integer | |||
externallyCancelled | boolean | <optional> | false |
- Type:
- object
(static) makeDialogResult(cancelled, confirmed, buttonIndex, optionIndex, buttonText, value, externallyCancelledopt) → {object}
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
cancelled | boolean | |||
confirmed | boolean | |||
buttonIndex | integer | |||
optionIndex | integer | |||
buttonText | string | |||
value | string | |||
externallyCancelled | boolean | <optional> | false |
- 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.
| Name | Type | Description |
|---|---|---|
cancelled | boolean | |
enteredText | string |
- Type:
- object