diff --git a/src/custom-components/ReorderableList.tsx b/src/custom-components/ReorderableList.tsx index 06eb023..9e89a4f 100644 --- a/src/custom-components/ReorderableList.tsx +++ b/src/custom-components/ReorderableList.tsx @@ -52,6 +52,13 @@ export function ReorderableList(props: ReorderableListProps) { } } + function saveOnBackout(e: Event) { + const event = e as CustomEvent; + if (event.detail.button == GamepadButton.CANCEL) { + toggleReorderEnabled(); + } + } + return (
(props: ReorderableListProps) { onSecondaryButton={toggleReorderEnabled} onSecondaryActionDescription={reorderEnabled ? 'Save Order' : 'Reorder'} onClick={toggleReorderEnabled} + onButtonDown={saveOnBackout} > {entryList.map((entry: ReorderableEntry) => (